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

cryptpad: 3.0.0 -> 3.0.1 #67975

Merged
merged 2 commits into from Sep 7, 2019
Merged

cryptpad: 3.0.0 -> 3.0.1 #67975

merged 2 commits into from Sep 7, 2019

Conversation

blitz
Copy link
Contributor

@blitz blitz commented Sep 2, 2019

Motivation for this change

Update to latest stable release.

Things done
  • Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
  • 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 nix-review --run "nix-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.
Notify maintainers

cc @zimbatm

@blitz
Copy link
Contributor Author

blitz commented Sep 2, 2019

Mmh. This triggers a weird npm issue even though none of the dependencies have actually changed from 3.0.0.

builder for '/nix/store/wlnb9m3arywjr24478mv28g58pzwp7ir-node-cryptpad-3.0.1.drv' failed with exit code 1; last 10 log lines:
  get-folder-size@2.0.1 /nix/store/g3xcgynrgcsgxvvm7ky8zawzvk16zzgf-node-cryptpad-3.0.1/lib/node_modules/cryptpad/node_modules/get-folder-size
  gar@1.0.4 /nix/store/g3xcgynrgcsgxvvm7ky8zawzvk16zzgf-node-cryptpad-3.0.1/lib/node_modules/cryptpad/node_modules/gar
  tiny-each-async@2.0.3 /nix/store/g3xcgynrgcsgxvvm7ky8zawzvk16zzgf-node-cryptpad-3.0.1/lib/node_modules/cryptpad/node_modules/tiny-each-async
  npm ERR! cb() never called!
  
  npm ERR! This is an error with npm itself. Please report this error at:
  npm ERR!     <https://npm.community>
  
  npm ERR! A complete log of this run can be found in:
  npm ERR!     /build/.npm/_logs/2019-09-02T23_20_11_322Z-debug.log

@zimbatm
Copy link
Member

zimbatm commented Sep 3, 2019

try with node2nix 1.7.0

@blitz
Copy link
Contributor Author

blitz commented Sep 4, 2019

@GrahamcOfBorg build cryptpad

@infinisil
Copy link
Member

@GrahamcOfBorg build cryptpad

(need to be known by ofborg to be able to do builds)

@blitz
Copy link
Contributor Author

blitz commented Sep 4, 2019

The build currently fails because of the NPM package chainpad-server-3.0.4 fails to be fetched. This is weird, because NPM has this package.

npm ERR! code E404
npm ERR! 404 Not Found - GET http://www.example.com/chainpad-server
npm ERR! 404
npm ERR! 404  'chainpad-server@3.0.4' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it (or use the name yourself!)
npm ERR! 404 It was specified as a dependency of 'cryptpad'
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, http url, or git url.

@infinisil
Copy link
Member

As @tilpner said, you should probably try the newest node2nix version

@blitz
Copy link
Contributor Author

blitz commented Sep 6, 2019

@infinisil @tilpner I'm using node2nix from the same nixpkgs revision and it generates the exact same output. So there is something else going on.

@infinisil
Copy link
Member

Ah damn, the generate.sh script doesn't pin nixpkgs. Can you add this as a first commit which fixes this?

diff --git a/pkgs/development/node-packages/generate.sh b/pkgs/development/node-packages/generate.sh
index dafbcb17f7e..6985462171b 100755
--- a/pkgs/development/node-packages/generate.sh
+++ b/pkgs/development/node-packages/generate.sh
@@ -1,5 +1,5 @@
 #!/usr/bin/env nix-shell
-#! nix-shell -i bash -p nodePackages.node2nix
+#! nix-shell -i bash -p nodePackages.node2nix -I nixpkgs=../../..
 
 set -eu -o pipefail

@infinisil
Copy link
Member

Oh sorry I didn't read your message, you're using node2nix from the same nixpkgs version? What's realpath $(which node2nix)?

@blitz
Copy link
Contributor Author

blitz commented Sep 6, 2019

@infinisil Pinning nixpkgs in the shebang line actually did help. I previously changed NIX_PATH, but apparently I messed something up or it doesn't propagate to nix-shell invocations. Weird.

Anyway, cryptpad 3.0.1 builds and runs now. What I still don't understand is that generate.sh (also with the now correctly pinned nixpkgs) updates the global node-env.nix. See here: blitz@d107b45 I've ignored these changes and it seems to be fine, but I guess this isn't intentional.

And thanks for the handholding here. Much appreciated!

@blitz
Copy link
Contributor Author

blitz commented Sep 6, 2019

@zimbatm I would appreciate another look here. Seems like I fixed my node2nix problems for now and everything works.

@zimbatm zimbatm merged commit 03deb7c into NixOS:master Sep 7, 2019
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.

None yet

3 participants