You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I don't have the ability to post the exact code that causes this to break. However it is a very strange issue that seems to be due to this library. I am using julia 1.9.0.
In the following code for some reason not all variables will be available in the callback. Changing the order of declaration doesn't seem to affect it. Nor does making the variable a global. The issue happens consistently and I'm not sure what can be done to debug.
pylib =pyimport("mypylib")
a, b =create()
x = Dates.Second(15)
nextGuiUpdateDateTime =1
c =5functioncallback(p1, p2)
@show a, x, c
@show nextGuiUpdateDateTime # doesnt workend
pylib.start_loop(callback)
The text was updated successfully, but these errors were encountered:
I still have the code, may try that. But I worked around it by making the main program loop in julia. Now it occurs to me having the main loop in python may be an anti-pattern for this lib. It also has the disadvantage of making stack traces very long and deep in the pythoncall chain.
Yea I figured it out, was simply not putting global in front of a variable. Strange how the bug presented itself though. Maybe the julia devs will want to improve the warning system for that.
Affects: PythonCall
I don't have the ability to post the exact code that causes this to break. However it is a very strange issue that seems to be due to this library. I am using julia 1.9.0.
In the following code for some reason not all variables will be available in the callback. Changing the order of declaration doesn't seem to affect it. Nor does making the variable a global. The issue happens consistently and I'm not sure what can be done to debug.
The text was updated successfully, but these errors were encountered: