pcxod / olex2

Other
12 stars 1 forks source link

Olex@LINUX #9

Closed masterofamn2 closed 2 weeks ago

masterofamn2 commented 2 weeks ago

Hi, I want to report some issues I have with running OLEX2 (dev-version) on LINUX (Arch). The current version starts and works just fine - once.

I.e. I download the zip, extract it and run olex and everything just works. When I close and reopen, however, things break badly, i.e. the html panel does not fully load and olex is unusable.

Python-log:

================= PYTHON ERROR ================= Olex2 Version 2024.09.12 svn.r2332d2e for OlexSys -- SVN Revision No. 7018

Traceback (most recent call last):
  File "/opt/soft/olex2/cctbx/cctbx_sources/boost_adaptbx/boost/python.py", line 22, in import_ext
    try: mod = __import__(name)
ModuleNotFoundError: No module named 'boost_python_meta_ext'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "<string>", line 287, in <module>
  File "/opt/soft/olex2/util/pyUtil/variableFunctions.py", line 11, in <module>
    import ExternalPrgParameters
  File "/opt/soft/olex2/util/pyUtil/PyToolLib/ExternalPrgParameters.py", line 9, in <module>
    from method_imp import *
  File "/opt/soft/olex2/util/pyUtil/PyToolLib/method_imp/__init__.py", line 2, in <module>
    from .shelx import *
  File "/opt/soft/olex2/util/pyUtil/PyToolLib/method_imp/shelx.py", line 11, in <module>
    import cctbx_olex_adapter as COA
  File "/opt/soft/olex2/util/pyUtil/CctbxLib/cctbx_olex_adapter.py", line 24, in <module>
    import cctbx_controller as cctbx_controller
  File "/opt/soft/olex2/util/pyUtil/CctbxLib/cctbx_controller.py", line 3, in <module>
    from my_refine_util import *
  File "/opt/soft/olex2/util/pyUtil/CctbxLib/my_refine_util.py", line 1, in <module>
    from cctbx import xray
  File "/opt/soft/olex2/cctbx/cctbx_sources/cctbx/xray/__init__.py", line 2, in <module>
    from cctbx.xray.ext import *
  File "/opt/soft/olex2/cctbx/cctbx_sources/cctbx/xray/ext.py", line 2, in <module>
    import boost_adaptbx.boost.python as bp
  File "/opt/soft/olex2/cctbx/cctbx_sources/boost_adaptbx/boost/python.py", line 40, in <module>
    ext = import_ext("boost_python_meta_ext")
  File "/opt/soft/olex2/cctbx/cctbx_sources/boost_adaptbx/boost/python.py", line 31, in import_ext
    raise ImportError(
ImportError: __import__("boost_python_meta_ext"): No module named 'boost_python_meta_ext'
  sys.path:
    /opt/soft/olex2/lib/python38.zip
    /opt/soft/olex2/lib/python3.8
    /opt/soft/olex2/lib/python3.8/lib-dynload
    /opt/soft/olex2/lib/python3.8/site-packages
    /home/XXX/.olex2/data/7a0d789349df4fed4732dd44bafcb83f
    /home/XXX/.olex2/data/7a0d789349df4fed4732dd44bafcb83f/site-packages
    /opt/soft/olex2
    /opt/soft/olex2/etc/scripts
    /opt/soft/olex2/util/pyUtil
    /opt/soft/olex2/util/pyUtil/misc
    /opt/soft/olex2/util/pyUtil/PyToolLib
    /opt/soft/olex2/util/pyUtil/PyToolLib/FileReaders
    /opt/soft/olex2/util/pyUtil/CctbxLib
    /opt/soft/olex2/util/pyUtil/HAR
    /opt/soft/olex2/util/pyUtil/NoSpherA2
    /opt/soft/olex2/util/pyUtil/PluginLib
    /opt/soft/olex2/cctbx/cctbx_sources/libtbx
    /opt/soft/olex2/cctbx/cctbx_sources/libtbx/pythonpath
    /opt/soft/olex2/cctbx/cctbx_sources
Variable olex2.news_img_link_url could not be found
Traceback (most recent call last):
  File "/opt/soft/olex2/util/pyUtil/olexFunctions.py", line 128, in GetParam
    handler = olx.phil_handler
AttributeError: module 'olx' has no attribute 'phil_handler'
An error occurred running the function/macro GetParam
Traceback (most recent call last):
  File "/opt/soft/olex2/util/pyUtil/olexFunctions.py", line 128, in GetParam
    handler = olx.phil_handler
AttributeError: module 'olx' has no attribute 'phil_handler'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/opt/soft/olex2/util/pyUtil/olexFunctions.py", line 690, in func
    retVal = f(*args, **kwds)
  File "/opt/soft/olex2/util/pyUtil/olexFunctions.py", line 1256, in GetParam
    return OV.GetParam_as_string(variable, default)
  File "/opt/soft/olex2/util/pyUtil/olexFunctions.py", line 202, in GetParam_as_string
    retVal = self.GetParam(variable, default)
  File "/opt/soft/olex2/util/pyUtil/olexFunctions.py", line 158, in GetParam
    sys.stderr.formatExceptionInfo()
  File "<string>", line 148, in formatExceptionInfo
NameError: name 'OV' is not defined

The olex logs of a working and crashing session are attached:

pcxod commented 2 weeks ago

Hello, are you using the 'start' script? It sets up some paths.

masterofamn2 commented 2 weeks ago

Yes, I am starting via the script, not the olex2 binary. Trying the latter already fails with missing libs as expected.

pcxod commented 2 weeks ago

So then this means that more libs are missing that are needed to run cctbx... I had a go at Arch Linux some time ago and cannot say I won that time...

But give me a moment - I observer the same in my DEV Linux version, I will try to fix it in a moment.

pcxod commented 2 weeks ago

OK, this was cause by old cctbx configuration lingering around. I have updated the code to refresh it in the case loading cctbx fails.. You can set www2 as the update repository in Help/Update Options. I would not recommend to to enable 'Always' for DEV though as I do not always upload binaries - you can type 'update' from the Olex2 command line to initiate manual update.

masterofamn2 commented 2 weeks ago

Wow - that was a quick and perfect fix.

Thank you very much!

pcxod commented 2 weeks ago

Oh, I discovered the real issue I created some time ago. Nothing urgent to update - just that cctbx will do 'cold start' every time with the previous "fix" that simply covered the real issue (cctbx paths were set only on win32!). The proper fix is out now...