This can occasionally happen if the public APMonitor server is temporarily unavailable or experiencing connectivity issues. When that occurs, functions such as apm_meas that rely on the remote server may return urlread errors.
One option is to wait and try again later once the server connection is restored. However, a more robust approach is to move to Python GEKKO, which allows you to run the optimization locally without requiring an internet connection.
GEKKO uses the same APMonitor backend solver, but it has a more modern and actively developed Python interface. It also provides improved functionality for dynamic optimization, estimation, and control.
You can find example Python scripts and tutorials here:
https://apmonitor.com/wiki/index.php/Main/GekkoPythonOptimization
With GEKKO you can run problems locally by installing the package:
pip install gekko
and then running models directly in Python.
Best regards,
John Hedengren
________________________________________
From: apmo...@googlegroups.com <apmo...@googlegroups.com> on behalf of Dr. Jalesh Purohit <jale...@ddu.ac.in>
Sent: Sunday, March 8, 2026 11:58 PM
To: apmo...@googlegroups.com <apmo...@googlegroups.com>
Subject: [APM] Reg. APMonitor apm_meas
Dear all,It seems that apm_meas (i.e. response = apm_meas(server,app,name,value)) is not responding. Some urlread errors. Can anyone please let me know why this is happening? Any solution for this problem.Thanks everyoneDr. Jalesh L. Purohit (PhD, IIT-Bombay),Professor, Chemical Engineering Department,D D University, NadiadMob: 91 9925665899https://scholar.google.com/citations?user=WeScPaIAAAAJ&hl=enDISCLAIMER: The information transmitted is intended only for the person or entity to which it is addressed and may contain confidential and/or privileged material which is the intellectual property of Dharmsinh Desai University (D.D.U., Nadiad). Any review, retransmission, dissemination or other use of, or taking of any action in reliance upon this information by persons or entities other than the intended recipient is strictly prohibited. If you are not the intended recipient, or the employee, or agent responsible for delivering the message to the intended recipient and/or if you have received this in error, please contact the sender and delete the material from the computer or device. Dharmsinh Desai University does not take any liability or responsibility for any malicious codes/software and/or viruses/Trojan horses that may have been picked up during the transmission of this message. By opening and solely relying on the contents or part thereof this message, and taking action thereof, the recipient relieves the Dharmsinh Desai University of all the liabilities including any damages done to the recipient's pc/laptop/peripherals and other communication devices due to any reason. -- -- APMonitor user's group e-mail list.- To post a message, send email to apmo...@googlegroups.com- To unsubscribe, send email to apmonitor+...@googlegroups.com- Visit this group at http://groups.google.com/group/apmonitor--- You received this message because you are subscribed to the Google Groups "apmonitor" group.To unsubscribe from this group and stop receiving emails from it, send an email to apmonitor+...@googlegroups.com.To view this discussion visit https://groups.google.com/d/msgid/apmonitor/CANYvMrsPnwnHs1965Nw6VdBs_Uz2VSSc4BnWmhS7EKJk6ZSvtQ%40mail.gmail.com.