Skip to content

Update pybind11 requirement from >=2.10.0 to >=3.0.3#348

Open
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/pip/pybind11-gte-3.0.3
Open

Update pybind11 requirement from >=2.10.0 to >=3.0.3#348
dependabot[bot] wants to merge 1 commit intomainfrom
dependabot/pip/pybind11-gte-3.0.3

Conversation

@dependabot
Copy link
Copy Markdown
Contributor

@dependabot dependabot bot commented on behalf of github Apr 14, 2026

Updates the requirements on pybind11 to permit the latest version.

Release notes

Sourced from pybind11's releases.

Version 3.0.3

Bug fixes:

  • Fixed TSS key exhaustion in implicitly_convertible() when many implicit conversions are registered across large module sets. #6020

  • Fixed heap-buffer-overflow in pythonbuf with undersized buffers by enforcing a minimum buffer size. #6019

  • Fixed virtual-inheritance pointer offset crashes when dispatching inherited methods through virtual bases. #6017

  • Fixed free(): invalid pointer crashes during interpreter shutdown with py::enum_<> by duplicating late-added def_property_static argument strings. #6015

  • Fixed function_record heap-type deallocation to call PyObject_Free() and decref the type. #6010

  • Hardened PYBIND11_MODULE_PYINIT and get_internals() against module-initialization crashes. #6018

  • Fixed static_pointer_cast build failure with virtual inheritance in holder_caster_foreign_helpers.h. #6014

  • Fixed ambiguous factory template specialization that caused compilation failures with nvcc + GCC 14. #6011

  • Fixed crash in def_readwrite for non-smart-holder properties of smart-holder classes. #6008

  • Fixed memory leak for py::dynamic_attr() objects on Python 3.13+ by clearing managed __dict__ contents during deallocation. #5999

  • Fixed binding of noexcept and ref-qualified (&, &&) methods inherited from unregistered base classes. #5992

Internal:

  • Moved tomlkit dependency to the dev dependency group. #5990

  • Switched to newer public CPython APIs (PyType_GetFlags and public vectorcall APIs where available). #6005

Tests:

  • Made an async callback test deterministic by replacing fixed sleep with bounded waiting. #5986

CI:

... (truncated)

Changelog

Sourced from pybind11's changelog.

Version 3.0.3 (March 31, 2026)

Bug fixes:

  • Fixed TSS key exhaustion in implicitly_convertible() when many implicit conversions are registered across large module sets. #6020

  • Fixed heap-buffer-overflow in pythonbuf with undersized buffers by enforcing a minimum buffer size. #6019

  • Fixed virtual-inheritance pointer offset crashes when dispatching inherited methods through virtual bases. #6017

  • Fixed free(): invalid pointer crashes during interpreter shutdown with py::enum_<> by duplicating late-added def_property_static argument strings. #6015

  • Fixed function_record heap-type deallocation to call PyObject_Free() and decref the type. #6010

  • Hardened PYBIND11_MODULE_PYINIT and get_internals() against module-initialization crashes. #6018

  • Fixed static_pointer_cast build failure with virtual inheritance in holder_caster_foreign_helpers.h. #6014

  • Fixed ambiguous factory template specialization that caused compilation failures with nvcc + GCC 14. #6011

  • Fixed crash in def_readwrite for non-smart-holder properties of smart-holder classes. #6008

  • Fixed memory leak for py::dynamic_attr() objects on Python 3.13+ by clearing managed __dict__ contents during deallocation. #5999

  • Fixed binding of noexcept and ref-qualified (&, &&) methods inherited from unregistered base classes. #5992

Internal:

  • Moved tomlkit dependency to the dev dependency group. #5990

  • Switched to newer public CPython APIs (PyType_GetFlags and public vectorcall APIs where available). #6005

Tests:

  • Made an async callback test deterministic by replacing fixed sleep with bounded waiting. #5986

... (truncated)

Commits
  • 1b49908 docs: add v3.0.3 and v3.1.0 changelog updates. (#6023)
  • c066c76 fix: add missing PYBIND11_ALWAYS_INLINE macro for v3.0.3 backports
  • 76efcb3 Bump version from v3.0.2 → v3.0.3
  • 0f41635 chore(deps): bump pygments from 2.17.2 to 2.20.0 in /docs (#6024)
  • 54a4615 chore(deps): bump requests from 2.32.4 to 2.33.0 in /docs (#6013)
  • d12037c chore(deps): update pre-commit hooks (#6002)
  • 64eecc4 chore(deps): bump the actions group with 3 updates (#6000)
  • c0ea8fc Fix heap-buffer-overflow in pythonbuf with undersized buffers (#6019)
  • 8d621d6 fix: detect virtual inheritance in add_base to prevent pointer offset crash (...
  • b6a616e fix: strdup "self" arg in def_property_static, partially revert #6010 (gh...
  • Additional commits viewable in compare view

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Note

Low Risk
Low risk change limited to build-time dependency constraints, but may surface compile/ABI incompatibilities in downstream extension builds if the project relied on older pybind11 behavior.

Overview
Updates pyproject.toml build-system requirements to raise the minimum pybind11 version from >=2.10.0 to >=3.0.3, allowing builds to use the latest pybind11 release.

Reviewed by Cursor Bugbot for commit 0da4501. Bugbot is set up for automated code reviews on this repo. Configure here.

Updates the requirements on [pybind11](https://github.com/pybind/pybind11) to permit the latest version.
- [Release notes](https://github.com/pybind/pybind11/releases)
- [Changelog](https://github.com/pybind/pybind11/blob/master/docs/changelog.md)
- [Commits](pybind/pybind11@v2.10.0...v3.0.3)

---
updated-dependencies:
- dependency-name: pybind11
  dependency-version: 3.0.3
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added Changed Required label for PR that categorizes merge commit message as "Changed" for changelog dependencies Pull requests that update a dependency file python Pull requests that update Python code labels Apr 14, 2026
@github-actions
Copy link
Copy Markdown

🤖 Cursor Dependency Analysis

Supply-Chain Malware Review

Reviewing how pybind11 is declared in the repo and cross-checking the malware report.

Verdict: benign

Checklist

  • Classic obfuscation / process spawning: The scanner’s shell_process_spawn hits are false positives: they match the C++ API name py::exec and comments containing “exec” in upstream pybind11 tests and docs, not execve, shells, or subprocess usage. No credible obfuscation or unexpected process-spawn patterns in the reported evidence.

  • Invisible Unicode / GlassWorm: Scanner reports Unicode: 0; nothing to support hidden-character tampering.

  • Dependency integrity: The update targets pybind11, the standard project at pybind/pybind11, not a typosquat. A 3.x line is consistent with real pybind11 releases; the PR body’s v3.0.3 changelog and fix list match a normal maintenance release. ghost_version_or_missing_tag on >=3.0.3 is almost certainly the tool not mapping a PEP 440 constraint to a git tag, not proof of a nonexistent PyPI version. maintainer_drift / npm-maintainers is misapplied to this PyPI package and is not evidence of publisher compromise.

  • Dependabot context: Report shows 0 changed lockfiles and 0 changed node/vendor paths in the scan metadata you provided—consistent with a small manifest-only bump. The long list of changed paths (including upstream .github/workflows/) reflects diffing the upstream library between tags/commits, not an automatic claim that your app PR rewrites those files; for a normal Dependabot PR you should still confirm the actual PR diff is only pyproject.toml / requirements as expected.

Scanner vs interpretation: The warn status is driven by heuristic noise (exec substring, workflow path touch, version-spec “ghost” heuristics), not by IOCs or Unicode findings. Treat those as low signal unless the merged PR contains unexpected files or scripts.

Actionable follow-up (non-malware): Independently validate build/API compatibility with pybind11 3.x (major bump); that is a correctness concern, not a supply-chain malware signal from this review.

Compatibility Analysis

Exploring the repository for pybind11 usage and build integration to produce a compatibility analysis.

1) Where pybind11 is used

Location Role
pyproject.toml ([build-system] requires) Build-time dependency so PEP 517 builds get headers/CMake helpers.
src/CMakeLists.txt (lines ~220–247) find_package(pybind11 CONFIG), optional FetchContent checkout if the package is missing.
src/python_bindings/fastvdf.cpp Only C++ binding TU: PYBIND11_MODULE, m.def(...), py::bytes, py::tuple, py::gil_scoped_release, py::make_tuple.

There is no py::class_, py::enum_, iostream integration, smart holders, or custom type casters in project src/. Vendored headers under .upstream-dependency/ are for reference/scanning, not normal app code.


2) Overlap with 3.0.3 / changed internals

Release notes emphasize fixes in implicitly_convertible, pythonbuf / iostream, virtual inheritance / add_base, py::enum_ / def_property_static, smart-holder def_readwrite, py::dynamic_attr, etc.

fastvdf.cpp does not use those APIs—only free functions and primitive/pytypes. So there is little direct API surface overlap with the listed behavioral fixes.


3) Risks / unknowns

  • Major 2 → 3: In general, consumers should rebuild the extension and run tests; this tree’s bindings are small, so compile break risk is low, but not zero until CI passes.
  • CMake vs. pyproject drift: If find_package(pybind11) fails, CMake FetchContent uses GIT_TAG v2.13.6 (src/CMakeLists.txt), which is not aligned with a declared >=3.0.3 build requirement. That path is a consistency and supportability risk (and matches the “maintainer drift” style hints in your scan artifacts).
  • Runtime: No evidence this module relies on the buggy subsystems above; remaining risk is generic (init/internals paths used by every module).

4) Recommendation

Merge-with-caveats: Merge after green CI on the PR branch; caveat: plan a small follow-up to bump FetchContent’s GIT_TAG to a 3.x tag (e.g. v3.0.3) so offline / no-pip fallbacks match the declared requirement, unless you explicitly intend 2.13.6 only for legacy environments (then document and reconsider the >=3.0.3 pin).


Malware Scan Summary

  • Status: warn
  • Warn only mode: true
  • Changed upstream files scanned: 21
  • Resolution strategy: commit_list
  • Changed node/vendor paths: 0
  • Changed lockfiles: 0
  • Resolved refs: from=n/a to=n/a
  • Unicode findings (post-allowlist): 0
  • Confusable findings (post-allowlist): 0
  • IOC findings (post-allowlist): 0
  • Heuristic findings (post-allowlist): 12

Top findings

  • tests/test_with_catch/test_interpreter.cpp:117 shell_process_spawn :: py::exec(R"(
  • tests/test_with_catch/test_interpreter.cpp:167 shell_process_spawn :: py::exec(R"(
  • tests/test_with_catch/test_interpreter.cpp:375 shell_process_spawn :: // When the interpreter is embedded, there is no execution frame, but py::exec
  • tests/test_with_catch/test_interpreter.cpp:377 shell_process_spawn :: py::exec("var = dict(number=42)");
  • include/pybind11/pybind11.h:1578 shell_process_spawn :: /// Initialize an array of slots based on the supplied exec slot and options.
  • docs/changelog.md:2058 shell_process_spawn :: - py::exec, py::eval, and py::eval_file now add the builtins
  • docs/changelog.md:2060 shell_process_spawn :: matching exec and eval in pure Python.
  • docs/changelog.md:2746 shell_process_spawn :: - Added py::exec() as a shortcut for py::eval<py::eval_statements>()
  • .github/workflows/nightlies.yml:0 workflow_path_touch :: path-touch
  • .github/workflows/pip.yml:0 workflow_path_touch :: path-touch
  • pybind11:0 ghost_version_or_missing_tag :: >=3.0.3
  • pybind11:0 maintainer_drift :: >=2.10.0->>=3.0.3

Copy link
Copy Markdown

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 0da4501. Configure here.

Comment thread pyproject.toml
@@ -1,5 +1,5 @@
[build-system]
requires = ["setuptools>=42", "wheel", "setuptools_scm[toml]>=3.5.0", "pybind11>=2.10.0"]
requires = ["setuptools>=42", "wheel", "setuptools_scm[toml]>=3.5.0", "pybind11>=3.0.3"]
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

CMake fallback fetches outdated pybind11 v2.13.6 version

Medium Severity

The pyproject.toml build requirement now mandates pybind11>=3.0.3, but src/CMakeLists.txt line 244 has a FetchContent_Declare fallback pinned to GIT_TAG v2.13.6. If CMake can't find the pip-installed pybind11 (e.g., in certain CI or from-source builds), the fallback fetches a 2.x version that's incompatible with the 3.x minimum. This version mismatch can lead to build failures or subtle ABI incompatibilities since pybind11 3.0 is a major version with breaking changes.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 0da4501. Configure here.

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

Labels

Changed Required label for PR that categorizes merge commit message as "Changed" for changelog dependencies Pull requests that update a dependency file python Pull requests that update Python code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants