Skip to content

CI for pypi release#6

Merged
OttoVintola merged 10 commits into
mainfrom
release-ci
Jun 4, 2026
Merged

CI for pypi release#6
OttoVintola merged 10 commits into
mainfrom
release-ci

Conversation

@jessegrabowski

Copy link
Copy Markdown
Member
  • version python package from cargo.toml
  • switch from pypi key to trusted publisher
  • add release notes template
  • pin gh actions via commit sha for security

Since we're on pymc-devs, trusted publisher needs to be configured. We can ask @maresb nicely to help.

When you do a release, you will have to remember to bump the version in cargo.toml. Not perfect. The alternative is to do a sentinel version (0.0.0) and automatically write from a github tag on release, but I felt like that was a bit too much for this PR.

@jessegrabowski jessegrabowski added the enhancement New feature or request label Jun 3, 2026
@jessegrabowski

Copy link
Copy Markdown
Member Author

I also recommend you set up branch protections. Don't allow pushing directly to main, require reviews before merge, and require linear git history. Disable the "merge pull request" option.

@jessegrabowski

Copy link
Copy Markdown
Member Author

I also recommend you update you python pins (>=3.12, <3.15). 3.11 and below are not supported by the scientific stack per NEP 29

@jessegrabowski

Copy link
Copy Markdown
Member Author

Tests (both rust and python) were not passing. I cleaned them up a bit but I'm not sure what the intent of them is/was.

@aloctavodia

aloctavodia commented Jun 4, 2026

Copy link
Copy Markdown
Member

Thanks @jessegrabowski. This was a project started by @GStechschulte and then continued by @OttoVintola. So some mismatches have not been resolved yet, like the tests. I have added branch protection.

We discussed with Otto about following https://scientific-python.org/specs/spec-0000/

Comment thread tests/test_pgbart.py
BATCH_SIZE = (0.1, 0.1)
NUM_TREES = 50
NUM_PARTICLES = 10
NUM_TREES = 10

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

We could lower this more, even 2 should work

Comment thread tests/test_pgbart.py
with pm.Model() as model:
alpha = pm.Exponential("alpha", 1.0)
mu = pmb.BART("mu", X, np.log(Y), m=NUM_TREES)
mu = pmb.BART("mu", X, np.log(Y), m=NUM_TREES, response="gaussian")

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Unrelated to this PR, but mentioning it here before I forget: @OttoVintola, we should use the value "constant" instead of "gaussian", both for backward compatibility and because I find "Gaussian" potentially confusing. During fitting/training, we use a Gaussian, but after that, the response is a constant value.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

The default value errors fyi

@OttoVintola OttoVintola merged commit 3f8ae9a into main Jun 4, 2026
4 of 6 checks passed
@OttoVintola OttoVintola deleted the release-ci branch June 8, 2026 17:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants