1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 <2021> 2022 2023 2024 2025 | Index | 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 <2021> 2022 2023 2024 2025 |
<== Date ==> | <== Thread ==> |
---|
Subject: | Re: Python Script call from Button press, module not found |
From: | Matt Newville via Tech-talk <tech-talk at aps.anl.gov> |
To: | "Manoussakis, Adamandios" <manoussakis1 at llnl.gov> |
Cc: | "tech-talk at aps.anl.gov" <tech-talk at aps.anl.gov> |
Date: | Thu, 15 Apr 2021 10:47:48 -0500 |
Hi Kay,
Thanks for the link, I tried adding to my settings.ini file but still doesn’t seem to be finding the packages I am importing in my script (pandas, numpy).
org.csstudio.display.builder.runtime/python_path=C:\Users\PC\AppData\Local\Programs\Python\Python39\
I did find a fairly old post by you on tech talk and was wondering if this still applied to Phoebus/Jython (seems like jython still doesn’t work with numpy from looking around)
“CSS BOY scripts are executed in jython, not python.
Most of the default python modules are also available in jython, but when you install python modules with binary dependencies like numpy, MySQL_python, .. those are not available in jython.”
If this is the case, it seems like I might have to go the pythonIoc route but I really just wanted to have the script get called when a pv changed value (was using the button to write a value change causing the script to trigger).
Thanks,
Adam
From: Kasemir, Kay <kasemirk at ornl.gov>
Sent: Wednesday, April 14, 2021 10:41 AM
To: tech-talk at aps.anl.gov; Manoussakis, Adamandios <manoussakis1 at llnl.gov>
Subject: Re: Python Script call from Button press, module not found
See python_path in https://control-system-studio.readthedocs.io/en/latest/preference_properties.html#display-builder-runtime