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

Publication Package Pypi #54

Open
wants to merge 12 commits into
base: develop
Choose a base branch
from
Open

Conversation

Lookatator
Copy link
Member

@Lookatator Lookatator commented Jul 6, 2022

This PR:

  • updates and completes the setup.py

  • adds CI actions to:

    • try to push the package to test-pypi (with the correct version).
      This should only be triggered on release/** branches (inside pull requests).
      If the same version has already been pushed, this step will be skipped.

    • push the package to pypi:
      only when a tag is pushed on main branch.
      the tag mush be of the form vX.X.X

To test an installation of the package, you can run the following command:

pip install -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple qdax==0.0.2a1

@codecov-commenter
Copy link

codecov-commenter commented Jul 6, 2022

Codecov Report

Merging #54 (0a7b33a) into develop (f43659d) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff            @@
##           develop      #54   +/-   ##
========================================
  Coverage    89.49%   89.49%           
========================================
  Files           66       66           
  Lines         3864     3864           
========================================
  Hits          3458     3458           
  Misses         406      406           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f43659d...0a7b33a. Read the comment docs.

@Lookatator Lookatator marked this pull request as ready for review July 6, 2022 13:03
"jax==0.3.2",
"flax==0.4.1",
"brax==0.0.12",
"absl-py>=1.0.0",
Copy link
Collaborator

Choose a reason for hiding this comment

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

Are you sure about those >=? As discussed recently (#26), it is safer to use == for the dependencies.

Are the good practice different for the install_requires?

Copy link
Member Author

Choose a reason for hiding this comment

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

I think the install_requires from setup.py are quite different from the requirements.txt.

Basically, I changed it following the guidelines of the Python Package Authority documentation:
https://packaging.python.org/en/latest/discussions/install-requires-vs-requirements/

What do you think?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Interesting! Thanks for the link! Indeed, this seems fine 🙂

Copy link
Collaborator

Choose a reason for hiding this comment

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

Hi everyone, I'm passing through! I can confirm that setup.py should have >= -- try to use the lowest version possible that still allows your library to work, so that users have as much flexibility as possible. If anything, you may want to indicate it should be less than the next major version (e.g. >=1.0.0,<2.0.0) so that you're robust to API changes, but I don't think that's an issue here.

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

4 participants