Hello! I'm porting Rally (the official Elasticsearch benchmark tool) to PyOxidizer, and despite being stuck on 0.22.0 it works really well and required almost no change to our code. However Rally has this feature where it will load custom Python modules from another directory, for example https://github.com/elastic/rally-tracks/blob/master/eql/track.py.
Suppose /home/q/src/pyapp/other/path/amodule.py exists. The following CPython code does not raise an exception and loads the module:
installing files to /home/q/src/pyapp/./build/x86_64-unknown-linux-gnu/debug/install
Traceback (most recent call last):
File "<string>", line 4, in <module>
File "importlib", line 126, in import_module
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1004, in _find_and_load_unlocked
ModuleNotFoundError: No module named 'amodule'
error: cargo run failed
I would appreciate any ideas to help me debug this, or even turns this into a reproducer using only oxidizer_importer.
Hello! I'm porting Rally (the official Elasticsearch benchmark tool) to PyOxidizer, and despite being stuck on 0.22.0 it works really well and required almost no change to our code. However Rally has this feature where it will load custom Python modules from another directory, for example https://github.com/elastic/rally-tracks/blob/master/eql/track.py.
Suppose
/home/q/src/pyapp/other/path/amodule.py
exists. The following CPython code does not raise an exception and loads the module:But translated to PyOxidizer, I get an exception. Here's the
pyoxidizer.bzl
file that attempts to load the same module:But
pyoxidizer run
fails with:I would appreciate any ideas to help me debug this, or even turns this into a reproducer using only
oxidizer_importer
.