debugging python application fails


I’m developing a DIA application on a ConnectPort X4, and I haven’t been able lately to launch the application in debug mode. I get this error code:

Unable to launch the selected configuration because of the following errors:

Error while transferring files to the target: Read timed out

While I understand it may have something to do with file transfer, I don’t see what could be wrong. It fails when it is transfering

I’m using a wired connection on the LAN at the office, and I’m launching the application in debug from Digi ESP v1.3.0.


Sadly this is just something that happens at times. Some people rarely see it, other see it 80% of the time. Not sure why the difference.

Try new Ethernet cables, as a mis-negotated Half-vs-full duplex link with a modern switch causes a modest error rate which aggrevates this problem.

Just want to share more information on how debugging remotely mode issues could be solved when selecting a second file to debug on the same project folder.

[1]. Use a direct Ethernet cable to the machine. (Reading the above comment solved my issues, cause I was using wireless through an AP previously)
[2]. On Pydev Package Explorer –> (right click on your project to debug) –> Properties –> Digi Python Properties –> Browse –> (your .py file to debug) –> Apply
[3]. (On the editor screen, select the file to debug as your active page. Then on the top menu) select Run –> Debug Configurations –> Browse –> (Select the same project folder again). By now you’ll notice that the Main Module row is now refresh to the latest active file to debug


Thanks for your suggestion, however I’m debugging a DIA application so I don’t choose a particular file to debug, it’s always the same files that gets launched for debugging ( Also, I’m using good cables over a LAN where my computer is connected to the gateway through a single switch that says the wired connection is perfect (went through network diagnosis tools to confirm this with our sysadmin).

I found (if it can help others) that a clean reboot (using the CLI command “boot action=reset”) BEFORE launching the debug in the ESP helped a lot to reduce the likeliness of facing the “read timed out” issue.

That makes me wonder if there isn’t by chance a performance or failure/retry issue with the http file transfer that is used to send files over to the gateway. I had noticed before that it can take quite a long time to transfer even small files. If I combine this observation with the fact that having an application running makes the file transfer fail from time to time, well, it very much looks like a performance related issue (bad performance + network/IO latency = file transfer issue?). Things that make you go “mmmh”…

I hope Digi people read their forums and take this one into consideration :wink:

Same issue here with a ConnectPort X2 when running a python application and trying to run a new application using DIA.

Workaround: go in to the web interface of the ConnectPort and disable any python applications from Auto-starting, then reboot the ConnectPort. After it comes back up, I can run the new application normally.

Proper solution: I had a thread that was non-blocking and didn’t have any time.sleep() statements, meaning it would run continually. The processor was at 100% load, so it was too busy to load the new application. Once I added a sleep() statement, processor load dropped and the problem went away.