update python deployment github action#11
Conversation
… green-mbpt, 2) automatically update the version.py and h5py attributes before deployment
There was a problem hiding this comment.
Pull request overview
This PR updates the Python deployment GitHub Action to restrict PyPI deployments to only be triggered via repository_dispatch from the green-mbpt repository (when a new tag is created), rather than allowing direct pushes or manual triggers. It also adds automatic version bumping of version.py and HDF5 file __grids_version__ attributes before publishing.
Changes:
- Replaced
push/pull_request/workflow_dispatchtriggers with arepository_dispatchtrigger (version-updatetype) - Added an
update-and-deployjob that updatesversion.pyand HDF5 grid file version attributes, commits/pushes changes, and creates/pushes a matching tag - Updated downstream jobs (
build_sdist, publish) to depend onupdate-and-deployand use the dispatched tag as the checkout ref
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #11 +/- ##
==========================================
+ Coverage 96.43% 97.16% +0.72%
==========================================
Files 19 27 +8
Lines 1292 1658 +366
Branches 60 60
==========================================
+ Hits 1246 1611 +365
- Misses 27 28 +1
Partials 19 19 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 4 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 1 out of 1 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
egull
left a comment
There was a problem hiding this comment.
Im really not an expert on this... seems to make sense but I don't feel qualified :)
|
Tested a dry run; waiting for python application test before merging. Then we can release 0.3.3 from green-mbpt |
Serves two important purposes:
__grids_version__attribute in the grid files should be upgraded automatically (if not already correct). This action does that before deploying the package.