<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[API requests stop firing after a couple hours for custom module]]></title><description><![CDATA[<p dir="auto">Hi All,</p>
<p dir="auto">Just got my mirror up and running, I am still working on my custom MMM-CTA module, a module for Chicago public transit.  My issue is after a couple of hours of flawless running, the module stops sending API requests.  I have a scheduleUpdate() function handling the repeating requests.</p>
<p dir="auto">You can view my code here:  <a href="https://github.com/NateDee/MMM-CTA" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/NateDee/MMM-CTA</a></p>
<p dir="auto">It’s still a work in progress but, has anybody had similar issues?  No errors in my console logs, the requests just stop firing after about 2 hours.  I’m a bioinformatician so a bit of a jack of all trades, master of none, and somewhat new to JavaScript.</p>
<p dir="auto">Thanks for any help!</p>
]]></description><link>https://forum.magicmirror.builders/topic/6598/api-requests-stop-firing-after-a-couple-hours-for-custom-module</link><generator>RSS for Node</generator><lastBuildDate>Fri, 17 Jul 2026 04:34:53 GMT</lastBuildDate><atom:link href="https://forum.magicmirror.builders/topic/6598.rss" rel="self" type="application/rss+xml"/><pubDate>Sat, 17 Feb 2018 16:22:53 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to API requests stop firing after a couple hours for custom module on Sun, 25 Feb 2018 00:31:14 GMT]]></title><description><![CDATA[<p dir="auto">You could also do a console.log to see if you’re getting regular outputs after your request…</p>
]]></description><link>https://forum.magicmirror.builders/post/36233</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/36233</guid><dc:creator><![CDATA[cowboysdude]]></dc:creator><pubDate>Sun, 25 Feb 2018 00:31:14 GMT</pubDate></item><item><title><![CDATA[Reply to API requests stop firing after a couple hours for custom module on Sat, 24 Feb 2018 16:05:43 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/mochman" aria-label="Profile: mochman">@<bdi>mochman</bdi></a> after 10 hours it’s still running and updating!  I think that did the trick! It would always freeze during the overnight hours, I’m guessing I was having some hiccup for when no buses and trains were running.  Do you have a thread open for your issue?</p>
<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/pinsdorf" aria-label="Profile: pinsdorf">@<bdi>pinsdorf</bdi></a>  I had logs running, including logging json respones, but I never saw any errors the requests would just stop.</p>
]]></description><link>https://forum.magicmirror.builders/post/36218</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/36218</guid><dc:creator><![CDATA[NateDee]]></dc:creator><pubDate>Sat, 24 Feb 2018 16:05:43 GMT</pubDate></item><item><title><![CDATA[Reply to API requests stop firing after a couple hours for custom module on Sat, 24 Feb 2018 13:54:22 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/natedee" aria-label="Profile: NateDee">@<bdi>NateDee</bdi></a> I tried the same thing.  The weird thing is that all the other modules update normally, just the one weather one.  Nay luck with your issue?</p>
]]></description><link>https://forum.magicmirror.builders/post/36208</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/36208</guid><dc:creator><![CDATA[mochman]]></dc:creator><pubDate>Sat, 24 Feb 2018 13:54:22 GMT</pubDate></item><item><title><![CDATA[Reply to API requests stop firing after a couple hours for custom module on Sat, 24 Feb 2018 08:09:58 GMT]]></title><description><![CDATA[<p dir="auto">First thing I’d try is logging HTTP request and response into a file to collect some more details to reason on. Don’t forget to log timestamps and all headers.</p>
<p dir="auto">Having said that, I think <a class="plugin-mentions-user plugin-mentions-a" href="/user/natedee" aria-label="Profile: NateDee">@<bdi>NateDee</bdi></a>’s explanation makes a lot of sense to me.</p>
]]></description><link>https://forum.magicmirror.builders/post/36197</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/36197</guid><dc:creator><![CDATA[pinsdorf]]></dc:creator><pubDate>Sat, 24 Feb 2018 08:09:58 GMT</pubDate></item><item><title><![CDATA[Reply to API requests stop firing after a couple hours for custom module on Sat, 24 Feb 2018 05:47:46 GMT]]></title><description><![CDATA[<p dir="auto">Mochman are you using a setTimeout() or setInterval() function to schedule your requests?  I was using a setTimeout() and just switched over to setInterval(), I will let you know how it goes.  Mine pretty much always cuts out within a few hours.</p>
<p dir="auto">From the javascript docs, setTimeout() calls the function once, and I rely on a call to a scheduleUpdate() function to call setTimeout() after each successful request.  If any hiccup in the request, setTimeout() won’t be called again.  However, setInterval() calls repeatedly unless told to stop, so no dependency on any successful runs.</p>
<p dir="auto">I’ll update you if that does the trick for me.</p>
]]></description><link>https://forum.magicmirror.builders/post/36194</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/36194</guid><dc:creator><![CDATA[NateDee]]></dc:creator><pubDate>Sat, 24 Feb 2018 05:47:46 GMT</pubDate></item><item><title><![CDATA[Reply to API requests stop firing after a couple hours for custom module on Sun, 18 Feb 2018 03:19:17 GMT]]></title><description><![CDATA[<p dir="auto">I have a similar issue with forecast-io.  Sometimes it updates for days, sometimes it stops updating after an hour or so.  I wish I could help fix your problem, but the only thing I did was add a small piece of text that shows when it was last updated so I can restart the mirror.</p>
]]></description><link>https://forum.magicmirror.builders/post/35840</link><guid isPermaLink="true">https://forum.magicmirror.builders/post/35840</guid><dc:creator><![CDATA[mochman]]></dc:creator><pubDate>Sun, 18 Feb 2018 03:19:17 GMT</pubDate></item></channel></rss>