Skip to content

python3Packages.libcst @ 1.7.0: Build fails on Darwin w/ OperationNotPermitted #394968

Closed

Description

@sarahec

Nixpkgs version

  • Unstable (25.05)

Describe the bug

This build error occurred during nixpkgs-review for langchain:

       > Running phase: buildPhase
       > Traceback (most recent call last):
       >   File "/nix/store/1sac2dm9dbd6iwxw3pdbzh739s5pw884-fetch-cargo-vendor-util/bin/fetch-cargo-vendor-util", line 15, in <module>
       >     import requests
       >   File "/nix/store/2kcy81nj3hb3c7ma0hg0ry8lbbd4cywa-python3-3.12.9-env/lib/python3.12/site-packages/requests/__init__.py", line 164, in <module>
       >     from .api import delete, get, head, options, patch, post, put, request
       >   File "/nix/store/2kcy81nj3hb3c7ma0hg0ry8lbbd4cywa-python3-3.12.9-env/lib/python3.12/site-packages/requests/api.py", line 11, in <module>
       >     from . import sessions
       >   File "/nix/store/2kcy81nj3hb3c7ma0hg0ry8lbbd4cywa-python3-3.12.9-env/lib/python3.12/site-packages/requests/sessions.py", line 15, in <module>
       >     from .adapters import HTTPAdapter
       >   File "/nix/store/2kcy81nj3hb3c7ma0hg0ry8lbbd4cywa-python3-3.12.9-env/lib/python3.12/site-packages/requests/adapters.py", line 81, in <module>
       >     _preloaded_ssl_context.load_verify_locations(
       > PermissionError: [Errno 1] Operation not permitted
       For full logs, run 'nix log /nix/store/pkhr1gzq6fvvmqgdih3diiaskxz447km-libcst-1.7.0-vendor-staging.drv'.

Steps to reproduce

  1. On Darwin, nix-shell -p nixpkgs-review --run "nixpkgs-review pr 394752 --print-result"
  2. Observe the libcst failure early in the build

Expected behaviour

[email protected] should build without error

Screenshots

No response

Relevant log output

error: builder for '/nix/store/pkhr1gzq6fvvmqgdih3diiaskxz447km-libcst-1.7.0-vendor-staging.drv' failed with exit code 1;
       last 18 log lines:
       > Running phase: unpackPhase
       > unpacking source archive /nix/store/9ghxb9ncd57zi358dp4z9bn4hq8nm1ql-source
       > source root is source/native
       > Running phase: patchPhase
       > Running phase: updateAutotoolsGnuConfigScriptsPhase
       > Running phase: buildPhase
       > Traceback (most recent call last):
       >   File "/nix/store/1sac2dm9dbd6iwxw3pdbzh739s5pw884-fetch-cargo-vendor-util/bin/fetch-cargo-vendor-util", line 15, in <module>
       >     import requests
       >   File "/nix/store/2kcy81nj3hb3c7ma0hg0ry8lbbd4cywa-python3-3.12.9-env/lib/python3.12/site-packages/requests/__init__.py", line 164, in <module>
       >     from .api import delete, get, head, options, patch, post, put, request
       >   File "/nix/store/2kcy81nj3hb3c7ma0hg0ry8lbbd4cywa-python3-3.12.9-env/lib/python3.12/site-packages/requests/api.py", line 11, in <module>
       >     from . import sessions
       >   File "/nix/store/2kcy81nj3hb3c7ma0hg0ry8lbbd4cywa-python3-3.12.9-env/lib/python3.12/site-packages/requests/sessions.py", line 15, in <module>
       >     from .adapters import HTTPAdapter
       >   File "/nix/store/2kcy81nj3hb3c7ma0hg0ry8lbbd4cywa-python3-3.12.9-env/lib/python3.12/site-packages/requests/adapters.py", line 81, in <module>
       >     _preloaded_ssl_context.load_verify_locations(
       > PermissionError: [Errno 1] Operation not permitted
       For full logs, run 'nix log /nix/store/pkhr1gzq6fvvmqgdih3diiaskxz447km-libcst-1.7.0-vendor-staging.drv'.

Additional context

No response

System metadata

  • system: "aarch64-darwin"
  • host os: Darwin 24.3.0, macOS 15.3.2
  • multi-user?: yes
  • sandbox: yes
  • version: nix-env (Nix) 2.24.12
  • channels(root): "nixpkgs"
  • nixpkgs: /nix/store/n5zhvsrwjrlyaimd3cp7s70j401iycx5-source

Are you using nix-darwin?

Yes, I am using nix-darwin.

Notify maintainers

@dotlambda


Note for maintainers: Please tag this issue in your pull request description. (i.e. Resolves #ISSUE.)

I assert that this issue is relevant for Nixpkgs

Is this issue important to you?

Add a 👍 reaction to issues you find important.

Activity

  1. added
    0.kind: bug
    6.topic: darwin
    on Mar 31, 2025
  2. TomaSajt commented on Mar 31, 2025

    @TomaSajt
    Contributor

    Known issue with Nix on darwin: the sandbox doesn't allow reading the $NIX_SSL_CERT_FILE, because it's not in the allowlist in the default nix sandbox profile.
    Try building with a relaxed sandbox.

  3. sarahec commented on Mar 31, 2025

    @sarahec
    ContributorAuthor

    Try building with a relaxed sandbox.

    That worked. Thank you very much.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    0.kind: bug6.topic: darwin

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions