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

pythonPackages.nbclassic: fix build failure due to nodejs deps #186703

Merged
merged 2 commits into from
Aug 18, 2022

Conversation

mofrim
Copy link
Contributor

@mofrim mofrim commented Aug 14, 2022

Description of changes

using v4.3.0 nbclassic github version as src for this package would require dealing with bower nodejs dependencies which would be, given the fact that bower is almost deprecated, cumbersome to deal with directly (i tried for a while...).

So i decided to use the Pypi-version where all node-deps are included. Also an new dependency notebook_shim had to be packaged.

I only started looking into this matter because another package i maintain manim did not build anymore because of nbclassic not building.

Unfortunately ATM nbclassic only builds with export NIXPKGS_ALLOW_INSECURE=1 because of pythonPackages.mistune, see also PR #186272.

Closes #186694, closes #185028.

Things done
  • Built on platform(s)
    • x86_64-linux
    • aarch64-linux
    • x86_64-darwin
    • aarch64-darwin
  • For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
  • Tested, as applicable:
  • Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
  • Tested basic functionality of all binary files (usually in ./result/bin/)
  • 22.11 Release Notes (or backporting 22.05 Release notes)
    • (Package updates) Added a release notes entry if the change is major or breaking
    • (Module updates) Added a release notes entry if the change is significant
    • (Module addition) Added a release notes entry if adding a new NixOS module
    • (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes
  • Fits CONTRIBUTING.md.

@mofrim mofrim requested review from FRidh and jonringer as code owners August 14, 2022 20:17
@mofrim mofrim added 8.has: package (new) This PR adds a new package 0.kind: build failure A package fails to build labels Aug 14, 2022
@ofborg ofborg bot requested a review from elohmeier August 14, 2022 20:25
@smancill smancill linked an issue Aug 14, 2022 that may be closed by this pull request
@smancill
Copy link
Contributor

@ofborg build python310Packages.nbclassic python310Packages.jupyterlab

@smancill
Copy link
Contributor

Ah, it cannot build on ofborg because of the insecure dependency.

@smancill
Copy link
Contributor

Result of nixpkgs-review pr 186703 run on x86_64-darwin 1

1 package marked as broken and skipped:
  • manim
3 packages failed to build:
  • python39Packages.jupyterlab
  • python39Packages.jupyterlab-lsp
  • python39Packages.jupytext
7 packages built:
  • python310Packages.jupyterlab
  • python310Packages.jupyterlab-lsp
  • python310Packages.jupytext
  • python310Packages.nbclassic
  • python310Packages.notebook_shim
  • python39Packages.nbclassic
  • python39Packages.notebook_shim

@SuperSandro2000 SuperSandro2000 changed the title pythonPackages.nbclassic: proposal for fixing build failure due to nodejs deps pythonPackages.nbclassic: fix build failure due to nodejs deps Aug 15, 2022
@mofrim mofrim force-pushed the fix-nbclassic branch 2 times, most recently from da130e5 to ddddfc7 Compare August 15, 2022 16:49
@smancill
Copy link
Contributor

smancill commented Aug 15, 2022

Note that since #186272 was merged just hours ago, this won't build when merged into master (thus nixpkgs-review will fail) until #186804 is merged.

@smancill
Copy link
Contributor

Result of nixpkgs-review pr 186703 run on x86_64-darwin 1

1 package marked as broken and skipped:
  • manim
3 packages failed to build:
  • python39Packages.jupyterlab
  • python39Packages.jupyterlab-lsp
  • python39Packages.jupytext
7 packages built:
  • python310Packages.jupyterlab
  • python310Packages.jupyterlab-lsp
  • python310Packages.jupytext
  • python310Packages.nbclassic
  • python310Packages.notebook-shim
  • python39Packages.nbclassic
  • python39Packages.notebook-shim

@smancill smancill added the 12.approvals: 1 This PR was reviewed and approved by one reputable person label Aug 17, 2022
@fogti
Copy link
Contributor

fogti commented Aug 18, 2022

Result of nixpkgs-review pr 186703 run on x86_64-linux

4 packages failed to build:
  • python39Packages.jupyterlab
  • python39Packages.jupyterlab-git
  • python39Packages.jupyterlab-lsp
  • python39Packages.jupytext
9 packages built:
  • manim
  • python310Packages.jupyterlab
  • python310Packages.jupyterlab-git
  • python310Packages.jupyterlab-lsp
  • python310Packages.jupytext
  • python310Packages.nbclassic
  • python310Packages.notebook-shim
  • python39Packages.nbclassic
  • python39Packages.notebook-shim
nix log /nix/store/gx97h2k4rdyd7jb7yj1mh5bk85gxs3cz-python3.9-jupyterlab_server-2.15.0.drv (build failure)
Sourcing python-remove-tests-dir-hook
Sourcing python-catch-conflicts-hook.sh
Sourcing python-remove-bin-bytecode-hook.sh
Sourcing pip-build-hook
Using pipBuildPhase
Using pipShellHook
Sourcing pip-install-hook
Using pipInstallPhase
Sourcing python-imports-check-hook.sh
Using pythonImportsCheckPhase
Sourcing python-namespaces-hook
Sourcing pytest-check-hook
Using pytestCheckPhase
@nix { "action": "setPhase", "phase": "unpackPhase" }
unpacking sources
unpacking source archive /nix/store/jkw7pif6r27bbr3rjg7wzaq0v58cldm2-jupyterlab_server-2.15.0.tar.gz
source root is jupyterlab_server-2.15.0
setting SOURCE_DATE_EPOCH to timestamp 1580601600 of file jupyterlab_server-2.15.0/tests/translations/jupyterlab-some-package/setup.py
@nix { "action": "setPhase", "phase": "patchPhase" }
patching sources
substituteStream(): WARNING: pattern '--cov jupyterlab_server --cov-report term-missing --cov-report term:skip-covered' doesn't match anything in file 'pyproject.toml'
@nix { "action": "setPhase", "phase": "configurePhase" }
configuring
no configure script, doing nothing
@nix { "action": "setPhase", "phase": "buildPhase" }
building
Executing pipBuildPhase
Creating a wheel...
WARNING: The directory '/homeless-shelter/.cache/pip' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo,>
Processing /build/jupyterlab_server-2.15.0
  Running command Preparing metadata (pyproject.toml)
  Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: jupyterlab_server
  Running command Building wheel for jupyterlab_server (pyproject.toml)
  Building wheel for jupyterlab_server (pyproject.toml) ... done
  Created wheel for jupyterlab_server: filename=jupyterlab_server-2.15.0-py3-none-any.whl size=54080 sha256=b08ddaa7f8415c41cfce74313dfc1cbd435dd389a16d9252d85c0c8f141090ff
  Stored in directory: /build/pip-ephem-wheel-cache-yj1av9rv/wheels/ea/50/d0/bb312eac99e64e2f2443d5b29455912f4555a3bb2cd18bb678
Successfully built jupyterlab_server
Finished creating a wheel...
Finished executing pipBuildPhase
@nix { "action": "setPhase", "phase": "installPhase" }
installing
Executing pipInstallPhase
/build/jupyterlab_server-2.15.0/dist /build/jupyterlab_server-2.15.0
Processing ./jupyterlab_server-2.15.0-py3-none-any.whl
Requirement already satisfied: json5 in /nix/store/07ywxkyqpvad1vpdg9a84ipv6xm5gqjv-python3.9-pyjson5-0.8.5/lib/python3.9/site-packages (from jupyterlab-server==2.15.0) (0.8.5)
ERROR: Could not find a version that satisfies the requirement importlib-metadata>=3.6; python_version < "3.10" (from jupyterlab-server) (from versions: none)
ERROR: No matching distribution found for importlib-metadata>=3.6; python_version < "3.10"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0.kind: build failure A package fails to build 6.topic: python 8.has: package (new) This PR adds a new package 10.rebuild-darwin: 11-100 10.rebuild-linux: 11-100 12.approvals: 1 This PR was reviewed and approved by one reputable person
Projects
None yet
Development

Successfully merging this pull request may close these issues.

JupyterLab build fail python3.10-nbclassic-0.4.3: npm unavailable
4 participants