RoboDK Forum
Machining project Update followed immediately by RunCode doesn't work可打印版本

+- RoboDK Forum (//www.sinclairbody.com/forum)
+-- Forum: RoboDK (EN) (//www.sinclairbody.com/forum/Forum-RoboDK-EN)
+ - - -论坛:RoboDK错误(//www.sinclairbody.com/forum/Forum-RoboDK-bugs)
+--- Thread: Machining project Update followed immediately by RunCode doesn't work (/Thread-Machining-project-Update-followed-immediately-by-RunCode-doesn-t-work)



Machining project Update followed immediately by RunCode doesn't work-hn-cso-12-19-2022

In the attached station, the followingdoes notresult in the program being executed:

Code:
from robodk import robolink

rdk = robolink.Robolink()
machining = rdk.Item("Path1 Settings")
program = rdk.Item("Path1")
machining.Update()
program.RunCode()

But the following (with a time.sleep(0.5))doesresult in the program being executed:
Code:
import time
from robodk import robolink

rdk = robolink.Robolink()
machining = rdk.Item("Path1 Settings")
program = rdk.Item("Path1")
machining.Update()
time.sleep(0.5)
program.RunCode()
It's not deterministic and depends on the amount of time between the Update and the RunCode. Note that Path1 is the generated program for the Path1 Settings machining project.

Please advise; how do I deterministically ensure that a program run following a machining project update always runs?

On macos. "About" menu item shows RoboDK v5.5.0.22337 but rdk.Version() shows '5.4.3.22337'.


RE: Machining project Update followed immediately by RunCode doesn't work-Albert-12-20-2022

Thank you for your detailed report. We fixed this issue on 1 week ago on Windows. We'll update Mac and Linux versions before the end of the year.