Good morning all! I am having trouble getting my p...
# ask-community
d
Good morning all! I am having trouble getting my python environment straightened out. In a flows/mymodule.py script I import mycustommodule and try to access its version attribute, which raises an AttributeError. The custom package absolutely has this attribute, I can verify that if I execute the script elsewhere and also from the command line with
python -c "import mycustommodule; print(mycustommodule.__version__)"
. The problem seems to be whenever prefect is imported, which happens if I explicitly import it or it happens implicitly if I execute a script from the flows/ dir. I can create a simple script,
flows/test.py
, with exactly two lines:
Copy code
import mycustommodule
print(mycustommodule.__version__)
And running it verbosely tells me that prefect gets imported, and the attribute call fails. But if I just move
test.py
up one folder, or anywhere else on my pc, it executes fine because it never imports prefect. What could be going wrong, and how can I address this?