Read the statement by Michael Teeuw here.
Calendar not updating
-
@sdetweil Can’t see any calendar errors in error.log now! :grinning_squinting_face:
But still my new events are not showing up when they should… -
-
@matt216 thank you… i posted a an additional grep thru the log to the issue
-
@matt216 cant see any errors… well not with the grep search you do
can u do this
pm2 stop all cd ~/MagicMirror npm start >somefile.txt 2>&1
wait, til UI up with no issues, or no updates
ctrl-q on MM screen to end
edit the somefile.txt
loo at messages after “Starting server on port”
-
pi@magicmirror:~/MagicMirror $ cat somefile.txt | grep calendar [02.01.2024 14:56.40.510] [LOG] Module helper loaded: calendar [02.01.2024 14:56.42.557] [LOG] Connecting socket for: calendar [02.01.2024 14:56.42.558] [LOG] Starting node helper for: calendar [02.01.2024 14:56.46.986] [LOG] Create new calendarfetcher for url: https://my.cal.url - Interval: 120000 [02.01.2024 14:57.13.099] [INFO] Calendar-Fetcher: Broadcasting 379 events from https://my.cal.url. [02.01.2024 14:59.23.139] [ERROR] Calendar Error. Could not fetch calendar: https://my.cal.url TypeError: fetch failed
-
[02.01.2024 14:59.23.139] [ERROR] Calendar Error. Could not fetch calendar: https://my.cal.url TypeError: fetch failed at Object.fetch (node:internal/deps/undici/undici:11576:11) at process.processTicksAndRejections (node:internal/process/task_queues:95:5) { cause: ConnectTimeoutError: Connect Timeout Error at onConnectTimeout (node:internal/deps/undici/undici:8522:28) at node:internal/deps/undici/undici:8480:50 at Immediate._onImmediate (node:internal/deps/undici/undici:8511:13) at process.processImmediate (node:internal/timers:476:21) { code: 'UND_ERR_CONNECT_TIMEOUT' } }
Timeout…
Let me know if the full somefile.txt by email is still wanted. -
@matt216 no… not needed…
-
@sdetweil If I enter my calendar URL in to a web browser I can download the ics file fine, FYI
-
@matt216 yes, it was a momentary delay, which caused the timeout… trying to see why the catch() block didn’t
-
@matt216 can u try updating modules/default/calendar/calendarfetcher.js like this
replace lines 58-84 with this . also added this to the issuetry { /// new code here // this will be the new line 58 fetch(url, { headers: headers, agent: httpsAgent }) .then(NodeHelper.checkFetchStatus) .then((response) => response.text()) .then((responseData) => { let data = []; try { data = ical.parseICS(responseData); Log.debug(`parsed data=${JSON.stringify(data)}`); events = CalendarFetcherUtils.filterEvents(data, { excludedEvents, includePastEvents, maximumEntries, maximumNumberOfDays }); } catch (error) { fetchFailedCallback(this, error); scheduleTimer(); return; } this.broadcastEvents(); scheduleTimer(); }) .catch((error) => { fetchFailedCallback(this, error); scheduleTimer(); }); } // new code here ========= catch(error){ console.error( "fetch for calendar url" +url + "failed error="+error.code); fetchFailedCallback(this, error); scheduleTimer(); } // end new code =====