Closed jason-neal closed 5 years ago
I can reproduce the problem using the python:latest
docker image. This is odd, at first glance, since the folder structure follows the python package schema correctly as far as I can tell. I will investigate further tomorrow.
e: After pip-installing the package from the develop branch, the site-packages folder for Starfish does not even contain grid_tools
... time to dive even deeper into the confused mess of python packaging practices 😄
Turns out the fix was easier than I thought! I managed to execute the code below without issue:
$ docker run --rm -ti python:latest bash
/# pip install git+https://github.com/iancze/starfish@develop#egg=astrostarfish
/# python -c "from Starfish.grid_tools import *"
/# python -c "from Starfish.grid_tools.interfaces import download_PHOENIX_models"
If the issue continues, open this back up @jason-neal, but hopefully it is solved!
PS: good catch. I struggle with bugs like these because they never come up in my development cycle!
Thanks, find_packages()
did the trick.
I am having issues accessing functions in grid_tools module after the recent changes. Is this just something I have missed?
As an exmaple
or
In this environment I only installed Starfish using the pip line above (no repo clone).
If I clone the repo and run
pip install -e .
from the starfish repo then the commands above do work.I assume there would be a simple change to __init__.py would possibly solve this. As to what the change is I am not sure.
I think this would also be a problem with
pip install astrostarfish
when it is uploaded to PyPI.