Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow deployment of prospect without DESI software stack #50

Merged
merged 4 commits into from Oct 27, 2020

Conversation

weaverba137
Copy link
Member

This PR allows the SDSS functionality of prospect to be deployed in an environment, such as NOIRLab Data Lab, that does not contain the DESI software stack.

I would like to very soon do further work to make prospect into a "real" Python package with a setup.py file and other infrastructure that would make it installable with pip.

Copy link
Collaborator

@armengau armengau left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I did not test the notebook in the "Data Lab" environment

@weaverba137
Copy link
Member Author

That's OK, I have.

Copy link
Collaborator

@sbailey sbailey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok as-is, but it seems a bit messy to have a bunch of try/except around desi imports when much of the code still requires those imports to work, thus introducing a maintenance risk about where it is ok to use desi code or not and perhaps producing non-obvious errors.

If you want to proceed with these minimally-necessary-to-work changes, ok, but consider adding unit tests to check that the things that aren't supposed to require desi code still don't. That could be done via a Travis environment that doesn't install desiutil+, or even better if there is some importlib magic that could temporarily cause import desiutil etc to not work just for those tests, even if another test had already successfully import desiutil+.

py/prospect/myspecselect.py Outdated Show resolved Hide resolved
py/prospect/myspecupdate.py Outdated Show resolved Hide resolved
@weaverba137
Copy link
Member Author

I agree that it is a bit messy right now. Data Lab at NOIRLab are pushing aggressively to release a spectrum data access service, and interactive plots with prospect is one of the end-user applications they are targeting. This branch is considered good enough to satisfy milestones associated with that.

In order to even have unit tests, we need to clean up the code and make this a real Python package, as mentioned above and in #49.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants