gafusion / omas

Ordered Multidimensional Array Structure
http://gafusion.github.io/omas
MIT License
30 stars 14 forks source link

Request for version bump #235

Closed LiamPattinson closed 1 year ago

LiamPattinson commented 1 year ago

I'm finishing up some work on a PR for Pyrokinetics which is pulling in OMAS as a dependency, but since the latest updates to the build system aren't yet pushed to PyPI, I'm currently having to tell pip to install a specific git commit of OMAS rather than just using the version. Would it be possible to release a version 0.90.1/0.91?

smithsp commented 1 year ago

Done. Thanks @orso82 for a good build/release system.

orso82 commented 1 year ago

@smithsp my standard workflow to release a new version is:

  1. edit omas/omas/version
  2. create a commit with message version X.Y.Z and push (the format must be this for make tag to work)
  3. run make tag
  4. run make pypi

I suspect that you're skipping 1-3 in the process? or doing it somewhat differently?

image
smithsp commented 1 year ago

I just forgot to git push after step 2. In the Makefile, it has git push --tags, but that doesn't seem to pick up the branch push. I have now pushed it.

orso82 commented 1 year ago

That explains it 👍

orso82 commented 1 year ago

Though the commit message should have been version 0.91.0. I am surprised that make tag worked? Or maybe you tagged it manually?

image
smithsp commented 1 year ago

I used make tag. It seemed to work fine.

LiamPattinson commented 1 year ago

Thanks for this!

If there are issues with keeping things consistent with versioning, the approach I normally use is to have setuptools-scm create a _version.py file dynamically from the git tags during installation, and the publishing step is handled by GitHub workflows (here's an example of how we do it in Pyrokinetics). That way, we only need to create a new release on GitHub, and both the in-package version file and the PyPI upload are handled automatically. I could try implementing something similar here if you're interested.

orso82 commented 1 year ago

Thank you for the offer @LiamPattinson but at this point the process that we have works and it takes me just a few seconds to make a new release ;) also in OMAS a lot of things are done via the Makefile, so there is some consistency with that approach. But definitely something to keep in mind for new projects!