Skip to content

Update minimum dependencies in accordance with SPEC 0 - #43031

Merged
vbraun merged 9 commits into
sagemath:developfrom
vincentmacri:update-conda
Oct 22, 2026
Merged

vbraun merged 9 commits into
sagemath:developfrom
vincentmacri:update-conda

Conversation

@vincentmacri

@vincentmacri vincentmacri commented Oct 20, 2026 •

Copy link
Copy Markdown
Member

Drop support for old dependencies according to SPEC 0 and update the conda lock files accordingly. In the process of updating the conda lock files, a new version of ty was pulled in with new diagnostics that I added to the ignore list in pyproject.toml because fixing them is out of scope for this PR.

This PR was partly done in order to minimize the diffs for when we eventually get a PR submitted that adds Python 3.15 support, since that will involve regenerating the lock files as well. By pure coincidence this PR is perfectly timed to deal with https://discuss.python.org/t/information-for-python-users-regarding-emudhra-emsign-ca-certificate-security-incident/109576

📝 Checklist

  • The title is concise and informative.
  • The description explains in detail what this PR is about.
  • I have linked a relevant issue or discussion.
  • I have created tests covering the changes.
  • I have updated the documentation and checked the documentation preview.

⌛ Dependencies

@vincentmacri vincentmacri added the dependencies Pull requests that update a dependency file label Oct 20, 2026
@github-actions

github-actions Bot commented Oct 20, 2026 •

Copy link
Copy Markdown

Documentation preview for this PR (built with commit bfca887; changes) is ready! 🎉
This preview will update shortly after each push to this PR.

@vincentmacri

Copy link
Copy Markdown
Member Author

Due to https://discuss.python.org/t/information-for-python-users-regarding-emudhra-emsign-ca-certificate-security-incident/109576 I am increasing the priority of this to blocker as conda refuses to resolve with the current version of ca-certificates in our lock files.

@dimpase

dimpase commented Oct 21, 2026

Copy link
Copy Markdown
Member

@codex review

@dimpase

dimpase commented Oct 21, 2026

Copy link
Copy Markdown
Member

trying something now, sorry :-)

@tobiasdiez tobiasdiez left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Only small nitpik, otherwise looks good. Thanks a lot for this PR!

Comment thread pyproject.toml Outdated
'mpmath >=1.1.0',
'networkx >=3.5',
'numpy >=1.25',
'numpy >=2.2.24',

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Could you also please use the same constraints in the requires section above. Thanks!

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.

I realized I didn't bump the minimum dependencies as much as I should have. I've bumped all the numpy constraints to >= 2.3.0 and also bumped a few more dependencies further.

@dimpase

dimpase commented Oct 21, 2026

Copy link
Copy Markdown
Member

do we need to update uv.lock too?

@vincentmacri

Copy link
Copy Markdown
Member Author

do we need to update uv.lock too?

Yes. Whether I can get that to work is a separate issue, but I will try. Before the CA issue I was happy to leave the uv.lock update for later, but with that we should really do that ASAP.

@vincentmacri

Copy link
Copy Markdown
Member Author

We should bump matplotlib to >= 3.11.0, but it is failing to resolve dependencies with that. Leaving it for now.

Comment thread tools/update-conda.py
content = f.read()
f.seek(0, 0)
# Override conda's cysignals after solving its dependencies;
# conda-forge does not yet provide Sage's cysignals release.

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.

Newest cysignals is available in conda-forge now thanks to @saraedum.

@vincentmacri

Copy link
Copy Markdown
Member Author

uv commands are failing for me on sage_numerical_backends_coin...

@vincentmacri

Copy link
Copy Markdown
Member Author

I had to remove sage_numerical_backends_coin from pyproject.toml to get uv lock to work. Not sure how we want to proceed as I don't know what that package is even for. Seems it isn't maintained as it hasn't had a release since 2024.

@orlitzky

Copy link
Copy Markdown
Contributor

uv commands are failing for me on sage_numerical_backends_coin...

It needs sagemath/sage-numerical-backends-coin#11 and a release. (It should only be emitting a deprecation warning, but it hasn't had a release since the last time @dimpase fixed setup.py)

@vincentmacri

Copy link
Copy Markdown
Member Author

uv commands are failing for me on sage_numerical_backends_coin...

It needs sagemath/sage-numerical-backends-coin#11 and a release. (It should only be emitting a deprecation warning, but it hasn't had a release since the last time @dimpase fixed setup.py)

In that case I suggest we leave it commented out in the pyproject.toml file until a new release is made so we can move forward with this PR in the meantime. Does that seem alright to you @orlitzky ?

@orlitzky

Copy link
Copy Markdown
Contributor

Yeah, I didn't even know it was in there, fine with me.

@dimpase dimpase left a comment

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.

I'll leave it commented out. I have an old PR to move it back into the sage tree, which is held by the macOS openmp PR, which hopefully gets in real soon...

@vbraun
vbraun merged commit d65aaed into sagemath:develop Oct 22, 2026
34 of 35 checks passed
vbraun pushed a commit that referenced this pull request Oct 22, 2026
Release Manager
gh-43034: build/pkgs: update certifi and pip for the emSign CA security incident
    
Depends on #43031.

Update Sage's certifi spkg from **2026.2.25 to 2026.10.19** and pip from
**26.0.1 to 26.2.2**, including their wheel checksums, to address the
compromised eMudhra/emSign intermediate CAs. The corrected certifi
bundle removes the affected emSign ECC G3 root while retaining
unaffected emSign roots. pip must also be updated because it vendors its
own certifi bundle.

These are the versions recommended in the [Python security
announcement](https://discuss.python.org/t/information-for-python-users-
regarding-emudhra-emsign-ca-certificate-security-incident/109576); see
also [GHSA-6q48-6c7w-9gw2](https://github.com/certifi/python-
certifi/security/advisories/GHSA-6q48-6c7w-9gw2).

This branch is based on #43031, which supplies the conda environment and
`uv.lock` security updates and disables the optional COIN backend. The
additional diff here is limited to the certifi and pip spkg versions and
checksums. Installations using system packages still depend on their
distribution's security updates.

Validation:

- Verified the wheel hashes against PyPI and passed Sage's checksum
verification for both packages.
- Previously installed both wheels offline in a fresh Python 3.14
environment; `pip check` passed, and both certificate bundles omit the
affected G3 root while retaining the unaffected emSign roots.
- After rebasing, `uv lock --check --offline` passes against the
repository's `pyproject.toml`.
- Confirmed all ten conda environments and `uv.lock` retain the fixed
certifi, pip, and uv versions; conda also retains the fixed ca-
certificates release.
- `git diff --check` passes. Full conda environments and Sage were not
rebuilt.

### 📝 Checklist

- [x] The title is concise and informative.
- [x] The description explains in detail what this PR is about.
- [x] I have linked a relevant issue or discussion.
- [ ] I have created tests covering the changes.
- [ ] I have updated the documentation and checked the documentation
preview.

### ⌛ Dependencies

- #43031
    
URL: #43034
Reported by: Dima Pasechnik
Reviewer(s): Marc Culler
@tobiasdiez

Copy link
Copy Markdown
Contributor

Thanks a lot for this cleanup. As a follow-up, I've refreshed the code a bit and removed old numpy 1.x workarounds: #43131 #43132 #43134

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file p: blocker / 1

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants