Open christophertubbs opened 3 months ago
It may be worth discussing whether we should move to editable mode as a general expectation for deployments, development or otherwise. I'm not sure I like it, but it would make certain things simpler.
Assuming we don't expect that for every deployment, I prefer not to use editable mode with DMOD's current multi-package setup. I think it's better to require ourselves to have the packages we use installed the same way for development as they will be for deployments. I see it as worth the small extra overhead, though I'm open to alternative ideas if there's a more convenient way to ensure we have this kind of environmental consistency for testing.
Regardless, I agree we should support at least some development activity without an active Internet connection.
Probably the simplest solution here is to add an option to _scripts/updatepackage.sh that causes pip's --no-deps
flag to be used.
This may be another sign that we need to (eventually) not have a bunch of individual packages like this all within the same repository, so we can potentially have that conversation as well (though perhaps in a different issue).
Im fairly certain this is unavoidable because of how we specify / need to specify several dependencies. To my best knowledge, pip
will re-pull any dependencies that are specified using a url like syntax (e.g. git+https://github.com/noaa-owp/hypy@master#egg=hypy&subdirectory=python
) b.c. pip
cannot be certain of the version. Like, @robertbartel mentioned, I think the best you can do is use pip
's --no-deps
flag in this case. If noaa-owp python repos were uploaded to pypi
this would not be an issue.
This pertains to ./scripts/update_package.sh
My internet went down this morning and I needed to update my codebase so all my changes were in place so I could test.
With everything already available locally (including all remote sources), I ran into issues like:
An internet connection should not be required 100% of the time just to develop.
Either handling needs to be added to avoid having to call
pip
whenever moving code into the virtual environment orupdate_script.sh
needs to be updated to 'install' in edit mode where packages don't need to be in the virtual environment to begin with.