Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

blender: install with python3Packages.requests, fixes #97250 #118987

Merged
merged 3 commits into from Apr 12, 2021

Conversation

ju1m
Copy link
Contributor

@ju1m ju1m commented Apr 10, 2021

Motivation for this change

Fixes #97250.
Some popular add-ons need python3Packages.requests (eg. BlenderBIM).
It could be provided with nix-shell -p python3Packages.requests --run blender because the wrapper only prepend to PYTHONPATH instead of setting it, but still it's a better user-experience to just have this dependency bundled by default.
There was also an attempt to wrap blender in a separate derivation in #97388 which could be resurrected.

Things done

requests can now be imported from the console and by add-ons, including its dependencies because buildPythonPath is now used.
I'm not setting PYTHON_REQUESTS_PATH because WITH_PYTHON_INSTALL_REQUESTS=OFF, and I guess setting PYTHON_NUMPY_PATH is useless as well but I'm not removing it, however PYTHON_NUMPY_INCLUDE_DIRS would likely still be needed because WITH_PYTHON_NUMPY=ON.

FIXME

When running the "Render presets thumbs" of the community module Archipack, the No module named 'numpy' error is still raised without my knowing why. That kind of error was previously mentioned here #82337 but believed to be fixed in #82341.

  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
  • Built on platform(s)
    • NixOS
    • macOS
    • other Linux distributions
  • Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
  • Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
  • Tested execution of all binary files (usually in ./result/bin/)
  • Determined the impact on package closure size (by running nix path-info -S before and after)
  • Ensured that relevant documentation is up to date
  • Fits CONTRIBUTING.md.

ju1m and others added 2 commits April 10, 2021 16:40
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
Co-authored-by: Sandro <sandro.jaeckel@gmail.com>
@SuperSandro2000 SuperSandro2000 merged commit a1bc838 into NixOS:master Apr 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Blender missing "requests" python library for add-ons
3 participants