Skip to content

Build failure on Python 3.14 due to outdated pydantic-core dependency #1451

@wang93wei

Description

@wang93wei

Initial Checks

Description

uv pip install mcp
  × Failed to build `pydantic-core==2.33.2`
  ├─▶ The build backend returned an error
  ╰─▶ Call to `maturin.build_wheel` failed (exit status: 1)

      [stdout]
      Running `maturin pep517 build-wheel -i /Users/alanwang/.cache/uv/builds-v0/.tmpVLUIV7/bin/python --compatibility off`
      cargo 1.90.0 (840b83a10 2025-07-30)
      Rust not found, installing into a temporary directory

      [stderr]
      Python reports SOABI: cpython-314-darwin
      Computed rustc target triple: aarch64-apple-darwin
      Installation directory: /Users/alanwang/Library/Caches/puccinialin
      Rustup already downloaded
      Installing rust to /Users/alanwang/Library/Caches/puccinialin/rustup
      warn: It looks like you have an existing rustup settings file at:
      warn: /Users/alanwang/.rustup/settings.toml
      warn: Rustup will install the default toolchain as specified in the settings file,
      warn: instead of the one inferred from the default host triple.
      info: profile set to 'minimal'
      info: default host triple is aarch64-apple-darwin
      warn: Updating existing toolchain, profile choice will be ignored
      info: syncing channel updates for 'stable-aarch64-apple-darwin'
      info: default toolchain set to 'stable-aarch64-apple-darwin'
      Checking if cargo is installed
      📦 Including license file `LICENSE`
      🍹 Building a mixed python/rust project
      🔗 Found pyo3 bindings
      🐍 Found CPython 3.14 at /Users/alanwang/.cache/uv/builds-v0/.tmpVLUIV7/bin/python
      📡 Using build options features, bindings from pyproject.toml
      💻 Using `MACOSX_DEPLOYMENT_TARGET=11.0` for aarch64-apple-darwin by default
         Compiling proc-macro2 v1.0.86
         Compiling unicode-ident v1.0.12
         Compiling target-lexicon v0.13.2
         Compiling python3-dll-a v0.2.13
         Compiling once_cell v1.19.0
         Compiling stable_deref_trait v1.2.0
         Compiling autocfg v1.3.0
         Compiling litemap v0.7.3
         Compiling writeable v0.5.5
         Compiling libc v0.2.155
         Compiling heck v0.5.0
         Compiling icu_locid_transform_data v1.5.0
         Compiling version_check v0.9.5
         Compiling icu_properties_data v1.5.0
         Compiling rustversion v1.0.17
         Compiling smallvec v1.14.0
         Compiling radium v0.7.0
         Compiling utf8_iter v1.0.4
         Compiling utf16_iter v1.0.5
         Compiling num-traits v0.2.19
         Compiling memoffset v0.9.1
         Compiling static_assertions v1.1.0
         Compiling memchr v2.7.4
         Compiling icu_normalizer_data v1.5.0
         Compiling write16 v1.0.0
         Compiling cfg-if v1.0.0
         Compiling lexical-util v1.0.6
         Compiling ahash v0.8.11
         Compiling serde v1.0.218
         Compiling tap v1.0.1
         Compiling wyz v0.5.1
         Compiling aho-corasick v1.1.3
         Compiling serde_json v1.0.140
         Compiling equivalent v1.0.1
         Compiling lexical-parse-integer v1.0.5
         Compiling funty v2.0.0
         Compiling percent-encoding v2.3.1
         Compiling hashbrown v0.14.5
         Compiling quote v1.0.36
         Compiling syn v2.0.82
         Compiling indoc v2.0.5
         Compiling zerocopy v0.7.34
         Compiling unindent v0.2.3
         Compiling regex-syntax v0.8.5
         Compiling indexmap v2.2.6
         Compiling getrandom v0.2.15
         Compiling form_urlencoded v1.2.1
         Compiling lexical-parse-float v1.0.5
         Compiling ryu v1.0.18
         Compiling itoa v1.0.11
         Compiling uuid v1.16.0
         Compiling base64 v0.22.1
         Compiling hex v0.4.3
         Compiling regex-automata v0.4.8
         Compiling synstructure v0.13.1
         Compiling bitvec v1.0.1
         Compiling zerofrom-derive v0.1.4
         Compiling yoke-derive v0.7.4
         Compiling zerovec-derive v0.10.3
         Compiling displaydoc v0.2.5
         Compiling icu_provider_macros v1.5.0
         Compiling pyo3-build-config v0.24.1
         Compiling zerofrom v0.1.4
         Compiling strum_macros v0.26.4
         Compiling serde_derive v1.0.218
         Compiling regex v1.11.1
         Compiling enum_dispatch v0.3.13
         Compiling num-integer v0.1.46
         Compiling num-bigint v0.4.6
         Compiling yoke v0.7.4
         Compiling strum v0.26.3
         Compiling pyo3-macros-backend v0.24.1
         Compiling pyo3-ffi v0.24.1
         Compiling pyo3 v0.24.1
         Compiling jiter v0.9.0
         Compiling pydantic-core v2.33.2 (/Users/alanwang/.cache/uv/sdists-v9/index/52da640fd0c2543d/pydantic-core/2.33.2/Csk7_wwtGk3_T8UHuC_3p/src)
         Compiling zerovec v0.10.4
         Compiling speedate v0.15.0
         Compiling pyo3-macros v0.24.1
      error: failed to run custom build command for `pyo3-ffi v0.24.1`

      Caused by:
        process didn't exit successfully:
      `/Users/alanwang/.cache/uv/sdists-v9/index/52da640fd0c2543d/pydantic-core/2.33.2/Csk7_wwtGk3_T8UHuC_3p/src/target/release/build/pyo3-ffi-3a915bcb0b4273f6/build-script-build`
      (exit status: 1)
        --- stdout
        cargo:rustc-check-cfg=cfg(Py_LIMITED_API)
        cargo:rustc-check-cfg=cfg(Py_GIL_DISABLED)
        cargo:rustc-check-cfg=cfg(PyPy)
        cargo:rustc-check-cfg=cfg(GraalPy)
        cargo:rustc-check-cfg=cfg(py_sys_config, values("Py_DEBUG", "Py_REF_DEBUG", "Py_TRACE_REFS", "COUNT_ALLOCS"))
        cargo:rustc-check-cfg=cfg(pyo3_disable_reference_pool)
        cargo:rustc-check-cfg=cfg(pyo3_leak_on_drop_without_reference_pool)
        cargo:rustc-check-cfg=cfg(Py_3_7)
        cargo:rustc-check-cfg=cfg(Py_3_8)
        cargo:rustc-check-cfg=cfg(Py_3_9)
        cargo:rustc-check-cfg=cfg(Py_3_10)
        cargo:rustc-check-cfg=cfg(Py_3_11)
        cargo:rustc-check-cfg=cfg(Py_3_12)
        cargo:rustc-check-cfg=cfg(Py_3_13)
        cargo:rustc-check-cfg=cfg(Py_3_14)
        cargo:rerun-if-env-changed=PYO3_CROSS
        cargo:rerun-if-env-changed=PYO3_CROSS_LIB_DIR
        cargo:rerun-if-env-changed=PYO3_CROSS_PYTHON_VERSION
        cargo:rerun-if-env-changed=PYO3_CROSS_PYTHON_IMPLEMENTATION
        cargo:rerun-if-env-changed=PYO3_PRINT_CONFIG
        cargo:rerun-if-env-changed=PYO3_USE_ABI3_FORWARD_COMPATIBILITY

        --- stderr
        error: the configured Python interpreter version (3.14) is newer than PyO3's maximum supported version (3.13)
        = help: please check if an updated version of PyO3 is available. Current version: 0.24.1
        = help: set PYO3_USE_ABI3_FORWARD_COMPATIBILITY=1 to suppress this check and build anyway using the stable ABI
      warning: build failed, waiting for other jobs to finish...
      💥 maturin failed
        Caused by: Failed to build a native library through cargo
        Caused by: Cargo build finished with "exit status: 101": `env -u CARGO MACOSX_DEPLOYMENT_TARGET="11.0" PYO3_BUILD_EXTENSION_MODULE="1"
      PYO3_ENVIRONMENT_SIGNATURE="cpython-3.14-64bit" PYO3_PYTHON="/Users/alanwang/.cache/uv/builds-v0/.tmpVLUIV7/bin/python"
      PYTHON_SYS_EXECUTABLE="/Users/alanwang/.cache/uv/builds-v0/.tmpVLUIV7/bin/python" "cargo" "rustc"
      "--features" "pyo3/extension-module" "--message-format" "json-render-diagnostics" "--manifest-path"
      "/Users/alanwang/.cache/uv/sdists-v9/index/52da640fd0c2543d/pydantic-core/2.33.2/Csk7_wwtGk3_T8UHuC_3p/src/Cargo.toml"
      "--release" "--lib" "--crate-type" "cdylib" "--" "-C" "link-arg=-undefined" "-C" "link-arg=dynamic_lookup" "-C"
      "link-args=-Wl,-install_name,@rpath/pydantic_core._pydantic_core.cpython-314-darwin.so"`
      Error: command ['maturin', 'pep517', 'build-wheel', '-i', '/Users/alanwang/.cache/uv/builds-v0/.tmpVLUIV7/bin/python', '--compatibility', 'off']
      returned non-zero exit status 1

      hint: This usually indicates a problem with the package or the build environment.
  help: `pydantic-core` (v2.33.2) was included because `mcp` (v1.16.0) depends on `pydantic` (v2.11.10) which depends on `pydantic-core`

Example Code

uv pip install mcp

Python & MCP Python SDK

python 3.14
MCP Python SDK:1.16.0

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingneeds reproneeds additional information to be able to reproduce bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions