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

Conda tweaks and Fix Example Notebook 1 #184

Merged
merged 4 commits into from
Dec 17, 2024
Merged

Conversation

aufdenkampe
Copy link
Collaborator

@aufdenkampe aufdenkampe commented Dec 16, 2024

This PR:

  • Updates environment.yml Python 3.10 and to pip install hsp2 directly from PyPI after creating the conda environment with all dependencies for running hsp2 and the example notebooks, all from one command:
    conda env create --file=environment.yml --solver=libmamba
  • Updates ReadMe to include instructions for above
  • Updates the examples/1_Intro_to_HSP2.ipynb Notebook to work with the repo 'src' directory reorganization for v0.11.0a1, the new environment file above, and on anyone's computer.
  • Temporarily removes __version__ from src/hsp2/hsp2/__init__.py, which will require a future fix to return the ability of the Python kernel to retrieve the version number. Note that the version can still be retrieved from conda.
    • This was throwing an error when running in development mode with conda develop.

Accepting this PR would also close:

@PaulDudaRESPEC, @timcera, @rburghol & @austinorr, the example 1 notebook now works by installing from the conda environment file. Most importantly this example notebook provides an example of how the IO manager should be used, as described in #182 (comment)
@PaulDudaRESPEC, this reverts things back to how @timcera set them up, so that we can merge PR #184 into `develop` as soon as possible, so that others can run the example with IOManager.
@aufdenkampe
Copy link
Collaborator Author

@PaulDudaRESPEC, I think we should merge this PR into develop as soon as possible, so that others can run the example with IOManager as a followup on the clarifications in #182 (comment)

Let's leave pandas version unconstrained in the recommended environment. I think we should frankly do the same for Python, changing these two lines to:
```yml
name: hsp2
  - python >=3.10
```
@PaulDudaRESPEC PaulDudaRESPEC merged commit 4201ea9 into develop Dec 17, 2024
11 checks passed
@timcera
Copy link
Contributor

timcera commented Dec 17, 2024

I did change the hard-coded version string to something dynamic, however, I don't think is has a use and could be removed (testing to make sure of course). I kept it there not because I thought it was useful, but because I didn't want to be disruptive. I think the idea of the version string is inherited from ancient Python project "skeletons" so that you can make bug reports (maybe that is the use case?), but hsp2 is a low-volume development community and I think a bit of overkill to have the version string programmatically available. As you pointed out you can easily get the installed version through pip or conda.

Basically, if the version string needs to come out to make things smoother for "conda develop" then take it out.

@aufdenkampe
Copy link
Collaborator Author

@PaulDudaRESPEC, thanks for merging this. I just found a fix for the versions thing and cued up this PR for you to review:

This was referenced Dec 17, 2024
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.

3 participants