Page 1 of 1

Pop up on running python child script

Posted: 26 May 2023, 14:29
by pab
I am using 4.5.1 on Mac 12.6
I have added a child script -> non threaded -> python. Everytime I make a change to the python code I am greeted with a pop-up with the message below. After clicking yes it runs fine but I don't want this to pop up everytime I make a change to the Python Script. This does not happen for a Lua script, only for a Python script. How can I get rid of it? I tried setting executeUnsafe=true in userset.txt but that does not help.

Pop up on making changes to Python non threaded child script
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Child script "/Floor" (via simExtSubprocess) is trying to execute the following:

/usr/local/bin/python3 /Applications/coppeliaSim_v4_5_1.app/Contents/MacOS/../Resources/python/pythonLauncher.py tcp://127.0.0.1:23261

Do you want to allow this and memorize this permission? The identifying string will be:

/usr/local/bin/python3_/Applications/coppeliaSim_v4_5_1.app/Contents/MacOS/../Resources/python/pythonLauncher.py_tcp://127.0.0.1:X_<scriptHash>

You can enable execution of unsafe commands by default with 'executeUnsafe=true' in /Users/pranav/.CoppeliaSim/usrset.txt, at your own risk.

Re: Pop up on running python child script

Posted: 26 May 2023, 16:22
by fferri
So, after you change usrset.txt, if you enter sim.getNamedBoolParam('settings.executeUnsafe') in the status bar, what does it say?

Re: Pop up on running python child script

Posted: 27 May 2023, 04:38
by pab
Many thanks for responding. I was able to fix it. After changing the flag to `executeUnsafe = true' in usrset.txt, I had to close CoppeliaSim and open it. Then it worked fine without the pop up. Curiously, I tried your command sim.getNamedBoolParam('settings.executeUnsafe') before and after changing usrset.txt and it gave me `nil' which I did not expect for both times. But my issue is fixed and I am all set. Thanks!

Re: Pop up on running python child script

Posted: 29 May 2023, 08:34
by fferri
pab wrote: 27 May 2023, 04:38 Curiously, I tried your command sim.getNamedBoolParam('settings.executeUnsafe') before and after changing usrset.txt and it gave me `nil'
Right. That would work in a version greater than 4.5.1 rev4, so not with current release.