You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+25Lines changed: 25 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -155,3 +155,28 @@ Note: Make sure all tests pass locally before creating a new release. The releas
155
155
156
156
Note 2: The version number in `src/pyscript/version` and the tag pushed to git (`X.Y.Z` in the example above) MUST MATCH! If they don't match the, the
157
157
action to create and publish the release won't start.
158
+
159
+
160
+
### How the Release Process Works
161
+
162
+
The release process is automated through GitHub Actions workflows. Here's what happens behind the scenes:
163
+
164
+
1. When a new tag is pushed, it triggers the release workflow
165
+
2. The workflow first checks that:
166
+
- The tag name matches the version in `src/pyscript/version`
167
+
- All tests pass successfully
168
+
169
+
3. If checks pass, the workflow:
170
+
- Builds the Python package using setuptools
171
+
- Creates source and wheel distributions
172
+
- Uploads the distributions to PyPI using twine
173
+
- Creates a GitHub release with the tag name
174
+
175
+
4. The version check is performed by the `check_tag_version()` function in setup.py, which:
176
+
- Reads the version from `src/pyscript/version`
177
+
- Compares it to the git tag that triggered the workflow
178
+
- Fails if they don't match exactly
179
+
180
+
5. The PyPI upload uses credentials stored as GitHub repository secrets
181
+
182
+
This automated process ensures consistent and reliable releases while preventing common issues like version mismatches or failed tests from being published.
0 commit comments