<?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[urequests and timeout?]]></title><description><![CDATA[<p dir="auto">Hi everyone.</p>
<p dir="auto">when loosing the wlan-connection (e.g. i turn of the router) my programm hangs at :<br />
response = urequests.post(db, data=payload,timeout=timeout_sec)</p>
<p dir="auto">It is not raising a exception, the program hangs for ever at this line.</p>
<p dir="auto">Any idea why?</p>
<p dir="auto">How do you implement a simple post-command with a timeout option?</p>
<p dir="auto">THX<br />
Martin</p>
<p dir="auto">I am using this <a href="http://urequests.py" target="_blank" rel="noopener noreferrer nofollow ugc">urequests.py</a> :<br />
<a href="https://github.com/micropython/micropyt" target="_blank" rel="noopener noreferrer nofollow ugc">https://github.com/micropython/micropyt</a> ... <a href="http://equests.py" target="_blank" rel="noopener noreferrer nofollow ugc">equests.py</a></p>
]]></description><link>https://forum.pycom.io/topic/4886/urequests-and-timeout</link><generator>RSS for Node</generator><lastBuildDate>Fri, 13 Nov 2026 16:48:24 GMT</lastBuildDate><atom:link href="https://forum.pycom.io/topic/4886.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 03 Jun 2019 11:22:51 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to urequests and timeout? on Fri, 24 Jan 2020 01:44:17 GMT]]></title><description><![CDATA[<p dir="auto">Andreas is right Martin. I had to resort to a wdt to get around urequest hangs. I tried adding a timeout to urequests, putting urequests in a different thread &amp; setting interrupt timers, nothing worked. Try import urequests; response=urequests.post(your_url, data=payload)</p>
]]></description><link>https://forum.pycom.io/post/31331</link><guid isPermaLink="true">https://forum.pycom.io/post/31331</guid><dc:creator><![CDATA[kjm]]></dc:creator><pubDate>Fri, 24 Jan 2020 01:44:17 GMT</pubDate></item><item><title><![CDATA[Reply to urequests and timeout? on Thu, 23 Jan 2020 03:37:38 GMT]]></title><description><![CDATA[<p dir="auto">Dear <a class="plugin-mentions-user plugin-mentions-a" href="/user/zmaier" aria-label="Profile: zmaier">@<bdi>zmaier</bdi></a>,</p>
<p dir="auto">maybe <a class="plugin-mentions-user plugin-mentions-a" href="/user/kjm" aria-label="Profile: kjm">@<bdi>kjm</bdi></a> has something to say about timeouts with the <code>urequests</code> module. Within [1], it looks like he worked around it using the watchdog timer.</p>
<p dir="auto">With kind regards,<br />
Andreas.</p>
<p dir="auto">[1] <a href="https://forum.pycom.io/topic/5617/delays-delays">https://forum.pycom.io/topic/5617/delays-delays</a></p>
]]></description><link>https://forum.pycom.io/post/31320</link><guid isPermaLink="true">https://forum.pycom.io/post/31320</guid><dc:creator><![CDATA[andreas]]></dc:creator><pubDate>Thu, 23 Jan 2020 03:37:38 GMT</pubDate></item></channel></rss>