Skip to content

[1.x Bug] uv add dbt-sqlserver fails to build dbt-core-experimental-parser==2.0.0a5: SSL certificate verification failed #15809

Description

@MichelLalancetteNortera

Is this a new bug in dbt-core?

  • I believe this is a new bug in dbt-core
  • I have searched the existing issues, and I could not find an existing issue for this bug

Current Behavior

Summary

When attempting to install dbt-sqlserver[mssql] (which transitively pulls in dbt-core -> dbt-core-experimental-parser==2.0.0a5), the build hook fails during the build step when fetching the release .whl from GitHub Releases. This was done on my work laptop. My personal computer works just fine.

The custom build backend (_dbt_sa_build) uses Python's standard urllib to download external assets, which triggers an SSL certificate verification failure:
[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: Missing Authority Key Identifier (_ssl.c:1082).

dbt_install_debug.txt

Root Cause
The dbt-core-experimental-parser package uses a custom PEP 517 build hook (_dbt_sa_build.build_wheel) that uses standard library urllib.request to dynamically fetch pre-compiled binaries from GitHub (https://github.com/dbt-labs/dbt-core/releases/download/...).

Unlike pip or uv (which bundle certifi or use native system trust stores), standard library urllib relies strictly on OpenSSL's certificate validation, which rejects the redirect target on Windows under Python 3.14 due to missing Authority Key Identifier (AKID) validation checks.

Diagnostic Verification
Running a direct urllib fetch against the target release URL produces the exact same trace:

uv run python -c "import urllib.request; urllib.request.urlopen('[https://github.com/dbt-labs/dbt-core/releases/download/v2.0.0-alpha.5/dbt_core_experimental_parser-2.0.0a5-py3-none-win_amd64.whl](https://github.com/dbt-labs/dbt-core/releases/download/v2.0.0-alpha.5/dbt_core_experimental_parser-2.0.0a5-py3-none-win_amd64.whl)')"

Traceback:

Traceback (most recent call last):
  File "Lib\ssl.py", line 1372, in do_handshake
    self._sslobj.do_handshake()
ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: Missing Authority Key Identifier (_ssl.c:1082)

urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: Missing Authority Key Identifier (_ssl.c:1082)>

DEBUG Calling _dbt_sa_build.build_wheel("C:\\Users\\user\\AppData\\Local\\uv\\cache\\builds-v0\\.tmpl183iH", {}, None)
DEBUG RuntimeError: failed to download https://github.com/dbt-labs/dbt-core/releases/download/v2.0.0-alpha.5/dbt_core_experimental_parser-2.0.0a5-py3-none-win_amd64.whl: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: Missing Authority Key Identifier (_ssl.c:1082)>
× Failed to build dbt-core-experimental-parser==2.0.0a5

Expected Behavior

Expected Behavior

dbt-core-experimental-parser (and transitively dbt-sqlserver) should install smoothly via standard Python package managers (uv, pip) without failing during the PEP 517 build phase.

Specifically:

  • The custom build backend (_dbt_sa_build) should gracefully handle SSL context initialization (e.g., using certifi or fallback SSL contexts) when fetching release assets over HTTPS, rather than relying strictly on unconfigured standard library urllib.
  • Pre-built wheel releases should ideally be published directly to PyPI to avoid out-of-band network calls during the build hook.

Steps To Reproduce

  1. In a clean directory with Python 3.14, run:
    uv add dbt-sqlserver[mssql]
    

Relevant log output

DEBUG Registry requirement already cached: text-unidecode==1.3
DEBUG Registry requirement already cached: zipp==4.1.0
DEBUG Registry requirement already cached: pycparser==3.0
DEBUG Using request connect timeout of 10s and read timeout of 30s
DEBUG Computed cache info: Timestamp(SystemTime { intervals: 134304084216742132 }), None, None, {}, {"src": Some(Timestamp(Timestamp(SystemTime { intervals: 134304066936194903 })))}. Most recently modified: pyproject.toml
DEBUG Cached revision does not match expected cache info for: test @ file:///C:/Users/user/Documents/test
DEBUG Found fresh response for: https://files.pythonhosted.org/packages/54/bc/d37f24f564cb32b3c13e470e5dfd8555b71c202580f701580ebd7e9cd10d/dbt_core_experimental_parser-2.0.0a5.tar.gz
   Building dbt-core-experimental-parser==2.0.0a5
DEBUG Building: dbt-core-experimental-parser==2.0.0a5
   Building test @ file:///C:/Users/user/Documents/test
DEBUG Building: test @ file:///C:/Users/user/Documents/test
DEBUG Creating build environment for: dbt-core-experimental-parser==2.0.0a5
DEBUG Performing direct build for test @ file:///C:/Users/user/Documents/test
DEBUG Project is contained in cache directory: `C:\Users\user\AppData\Local\uv\cache\sdists-v9\pypi\dbt-core-experimental-parser\2.0.0a5\cTQgk2rjy8sA-nkJ\src`
DEBUG No workspace root found, using project root
DEBUG Using base executable for virtual environment: C:\Users\user\AppData\Roaming\uv\python\cpython-3.14-windows-x86_64-none\python.exe
DEBUG Wheel excludes: ["__pycache__", "*.pyc", "*.pyo"]
DEBUG Writing wheel at C:\Users\user\AppData\Local\uv\cache\builds-v0\.tmpwFes8X\test-0.1.0-py3-none-any.whl
DEBUG Adding pth file to C:\Users\user\AppData\Local\uv\cache\builds-v0\.tmpwFes8X\test-0.1.0-py3-none-any.whl
DEBUG Source root: src
DEBUG Module path: test
DEBUG Adding metadata files to: C:\Users\user\AppData\Local\uv\cache\builds-v0\.tmpwFes8X\test-0.1.0-py3-none-any.whl
DEBUG Resolving build requirements
DEBUG Solving with installed Python version: 3.14.6
DEBUG Solving with target Python version: >=3.14.6
DEBUG Built `test @ file:///C:/Users/user/Documents/test` into `test-0.1.0-py3-none-any.whl`
DEBUG Adding direct dependency: packaging>=24
      Built test @ file:///C:/Users/user/Documents/test
DEBUG Found fresh response for: https://pypi.org/simple/packaging/
DEBUG Searching for a compatible version of packaging (>=24)
DEBUG Selecting: packaging==26.3 [compatible] (packaging-26.3-py3-none-any.whl)
DEBUG Found fresh response for: https://files.pythonhosted.org/packages/63/34/ba1c580383c9eada3711951fef0795c80b829a078d72188184bcab9dd527/packaging-26.3-py3-none-any.whl.metadata
DEBUG Tried 1 versions: packaging 1
DEBUG marker environment resolution took 0.003s
DEBUG Installing in packaging==26.3 in C:\Users\user\AppData\Local\uv\cache\builds-v0\.tmp0QoOFq
DEBUG Registry requirement already cached: packaging==26.3
DEBUG Installing build requirement: packaging==26.3
DEBUG Creating PEP 517 build environment
DEBUG Calling `_dbt_sa_build.get_requires_for_build_wheel()`
DEBUG Calling `_dbt_sa_build.build_wheel("C:\\Users\\user\\AppData\\Local\\uv\\cache\\builds-v0\\.tmpl183iH", {}, None)`
DEBUG Traceback (most recent call last):
DEBUG   File "<string>", line 11, in <module>
DEBUG     wheel_filename = backend.build_wheel("C:\\Users\\user\\AppData\\Local\\uv\\cache\\builds-v0\\.tmpl183iH", {}, None)
DEBUG   File "C:\Users\user\AppData\Local\uv\cache\sdists-v9\pypi\dbt-core-experimental-parser\2.0.0a5\cTQgk2rjy8sA-nkJ\src\_dbt_sa_build\__init__.py", line 66, in build_wheel
DEBUG     data = _fetch(url)
DEBUG   File "C:\Users\user\AppData\Local\uv\cache\sdists-v9\pypi\dbt-core-experimental-parser\2.0.0a5\cTQgk2rjy8sA-nkJ\src\_dbt_sa_build\__init__.py", line 59, in _fetch
DEBUG     raise RuntimeError(f"failed to download {url}: {last}")
DEBUG RuntimeError: failed to download https://github.com/dbt-labs/dbt-core/releases/download/v2.0.0-alpha.5/dbt_core_experimental_parser-2.0.0a5-py3-none-win_amd64.whl: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: Missing Authority Key Identifier (_ssl.c:1082)>
DEBUG Reverting changes to `pyproject.toml`
DEBUG Reverting changes to `uv.lock`
  × Failed to build `dbt-core-experimental-parser==2.0.0a5`
  ├─▶ The build backend returned an error
  ╰─▶ Call to `_dbt_sa_build.build_wheel` failed (exit code: 1)

      [stderr]
      Traceback (most recent call last):
        File "<string>", line 11, in <module>
          wheel_filename = backend.build_wheel("C:\\Users\\user\\AppData\\Local\\uv\\cache\\builds-v0\\.tmpl183iH", {}, None)
        File
      "C:\Users\user\AppData\Local\uv\cache\sdists-v9\pypi\dbt-core-experimental-parser\2.0.0a5\cTQgk2rjy8sA-nkJ\src\_dbt_sa_build\__init__.py",
      line 66, in build_wheel
          data = _fetch(url)
        File
      "C:\Users\user\AppData\Local\uv\cache\sdists-v9\pypi\dbt-core-experimental-parser\2.0.0a5\cTQgk2rjy8sA-nkJ\src\_dbt_sa_build\__init__.py",
      line 59, in _fetch
          raise RuntimeError(f"failed to download {url}: {last}")
      RuntimeError: failed to download
      https://github.com/dbt-labs/dbt-core/releases/download/v2.0.0-alpha.5/dbt_core_experimental_parser-2.0.0a5-py3-none-win_amd64.whl:
      <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: Missing Authority Key Identifier (_ssl.c:1082)>


hint: `dbt-core-experimental-parser` (v2.0.0a5) was included because `test` (v0.1.0) depends on `dbt-sqlserver` (v1.11.0) which depends on `dbt-core` (v1.12.0) which depends on `dbt-core-experimental-parser`
hint: Build failures usually indicate a problem with the package or the build environment
hint: If you want to add the package regardless of the failed resolution, provide the `--frozen` flag to skip locking and syncing

Environment

- OS: Windows 11 (`Windows-11-10.0.26200-SP0`)
- Python: CPython 3.14.6
- dbt: 1.12.0
- OpenSSL Version: OpenSSL 3.5.7 9 Jun 2026
- CA File Path: C:\Program Files\Common Files\SSL\cert.pem

Which database adapter are you using with dbt?

other (mention it in "Additional Context")

Additional Context

No response

Activity

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

Metadata

Metadata

Assignees

Labels

area:adaptersThe adapter framework/layer connecting Fusion to warehouses (dbt-adapter* crates).bugengine:v1Concerns the dbt Core v1 engine (Python).status:triageAwaiting initial triage / categorization.triagetype:bugA defect: Fusion behaves incorrectly versus expected/reference behavior.

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions