Repository navigation
Description
Environment
MagicMirror² version: 2.37.0
Node version: 22.23.1
npm version: 10.9.8
Platform: RPi 3b running Raspbian 11 bullseye
Which start option are you using?
node --run start:x11
Are you using PM2?
Yes
Module
None
Have you tried disabling other modules?
- Yes
- No
Have you searched if someone else has already reported the issue on the forum or in the issues?
- Yes
What did you do?
Configuration
var config = {
port: 8080,
address: "0.0.0.0",
ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1", "10.0.0.0/8"], // Set [] to allow all IP addresses
// or add a specific IPv4 of 192.168.1.5 :
// ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.1.5"],
// or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format :
// ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.3.0/28"],
language: "en",
timeFormat: 12,
units: "imperial",
modules: [
[...]
{
module: "MMM-GoogleCalendar",
header: "Family calendar",
position: "top_left",
config: {
calendars: [
{
symbol: "male",
calendarID: "redacted",
color: "#ff8e99"
},
{
symbol: "female",
calendarID: "redacted",
color: "#ffc0cb"
},
{
symbol: "hockey-puck",
calendarID: "redacted",
color: "#bcddff"
},
{
symbol: "people-group",
calendarID: "redacted",
color: "#8eff99"
},
{
url: "webcal://www.calendarlabs.com/ical-calendar/ics/76/US_Holidays.ics"
}//,
],
coloredSymbolOnly: true,
colored: true,
maximumNumberOfDays: 365,
hidePrivate: true,
showEnd: false,
getRelative: 0
}
},
[...]
]
};
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {module.exports = config;}
whatever https://github.com/randomBrainstormer/MMM-GoogleCalendar is using to fetch calendars (node-fetch)Steps to reproduce the issue:
Install https://github.com/randomBrainstormer/MMM-GoogleCalendar
Configure to show your authenticated calendars
View error in log
What did you expect to happen?
Calendars to download properly
What actually happened?
Error:
0|mm | [2026-07-08 14:23:51.273] [ERROR] [MMM-GoogleCalendar] MMM-GoogleCalendar Error. Could not fetch calendar: redacted Error: Error
0|mm | Message: Invalid response body while trying to fetch https://www.googleapis.com/calendar/v3/calendars/redacted/events?timeMin=2026-07-08T19%3A23%3A49.239Z&timeMax=2027-07-08T19%3A23%3A49.239Z&maxResults=10&singleEvents=true&orderBy=startTime: Premature close
0|mm | Stack: Error: Invalid response body while trying to fetch https://www.googleapis.com/calendar/v3/calendars/redacted/events?timeMin=2026-07-08T19%3A23%3A49.239Z&timeMax=2027-07-08T19%3A23%3A49.239Z&maxResults=10&singleEvents=true&orderBy=startTime: Premature close
0|mm | at Gaxios._request (/home/parnic/MagicMirror/modules/MMM-GoogleCalendar/node_modules/gaxios/build/src/gaxios.js:149:19)
0|mm | at process.processTicksAndRejections (node:internal/process/task_queues:104:5)
0|mm | at async OAuth2Client.requestAsync (/home/parnic/MagicMirror/modules/MMM-GoogleCalendar/node_modules/google-auth-library/build/src/auth/oauth2client.js:429:18)
Additional comments
This is caused by a regression in node v22.23.0 and v24.17.0, fixed in v22.23.1 and v24.18.0: nodejs/node#63989
The version of Electron bundled with MM 2.37.0 is v42.5.2 which uses node v24.17.0. Updating to Electron v42.6.0 or v43.1.0 corrects the issue.
I know you guys almost never do out-of-band releases, but this breaks any module dependent on the in-built node-fetch keep-alive behavior.
The workaround is to edit your MM package.json to set the electron optional dep to "electron": "^42.6.0", run npm install, and restart MM to let it pull down the newer version of Electron.
It looks like latest develop as of this writing is still using a bad version of Electron (v43.0.0 per 503c171)
Participation
- I am willing to submit a pull request for this change.
Activity
khassel commentedon Jul 8, 2026
I was wondering why we didn't see problems with this electron version in our tests. AFAIS this is a problem for "Keep-alive pooled HTTP requests" which are used e.g. with googleapi endpoints, not a general problem. Normal google ics calendars are working.
Would be interesting how many modules are affected by this bug.
KristjanESPERANTO commentedon Jul 9, 2026
We didn't see problems in our tests because the core doesn't rely on node-fetch.
However, my analysis shows that over 70 third-party modules have node-fetch as a direct dependency. And surely many more depend on it indirectly through their dependencies. This is a significant impact.
It's unfortunate because using node-fetch is no longer really necessary.
sdetweil commentedon Jul 9, 2026
He meant fetch in electron. The module uses fetch in the node engine in electron or fetch in node if server mode
KristjanESPERANTO commentedon Jul 9, 2026
My understanding is that the failing path in this report is not generic fetch in Electron, but node-fetch in the module’s dependency chain.
Either way, #4201 should address this. The bigger question is whether we should do an out-of-band release or wait for the regular one in October.
sdetweil commentedon Jul 9, 2026
I think I can walk the users thru upgrading electron
chore: update dependencies (#4201)
khassel commentedon Jul 9, 2026
@KristjanESPERANTO AFAIS the mentioned module doesn't use
node-fetch. It is not listed inpackage.json. The calendar entries are retrieved from a googleapi call. I was to lazy to dig deeper in this repository what they use, but looking into the mentioned nodejs issue I assume they use native node fetch.So I think all modules which are using a googleapi endpoint are affected, not those using
node-fetch.KristjanESPERANTO commentedon Jul 9, 2026
The module uses
node-fetchthrough its dependencies: https://github.com/randomBrainstormer/MMM-GoogleCalendar/blob/main/package-lock.json#L2264That's the dependency chain:
googleapis->googleapis-common->gaxios->node-fetch.sdetweil commentedon Jul 14, 2026
Impacted modules
MMM-GoogleCalendar
MMM-Fuel