!NhAsaYbbgmzHtXTPQJ:funklause.de

Nix NodeJS

209 Members
59 Servers

Load older messages


SenderMessageTime
30 Jul 2023
@gdamjan:spodeli.orggdamjanok, I'll try to cook something up14:47:08
@robert:funklause.dedotlambda
In reply to @lily:lily.flowers
That's entirely upstream's fault: https://github.com/matrix-org/matrix-appservice-irc/blob/0afb064635d37e039067b5b3d6423448b93026d3/package.json#L14
What would be a better thing to put in package.json?
15:41:21
@lily:lily.flowersLily FosterHonestly, idk. I'd rather either package.json have a direct way to chain lifecycle scripts or yarn just had a config setting for offline so flags wouldn't have to be propagated15:43:05
@robert:funklause.dedotlambda I'm improving remove-attr.py slightly in https://github.com/NixOS/nixpkgs/pull/246155 15:47:13
@lily:lily.flowersLily Foster
In reply to @robert:funklause.de
I'm improving remove-attr.py slightly in https://github.com/NixOS/nixpkgs/pull/246155
I'll try to review tonight! (US eastern tz)
15:49:51
31 Jul 2023
@robert:funklause.dedotlambda

I get

Error: invalid HTTP request

Caused by:
    invalid format

when running prefetch-npm-deps on https://github.com/cloudflare/workers-sdk/blob/wrangler%403.3.0/package-lock.json
Is that because of the empty string key?

{
  "name": "wrangler-root",
  "version": "0.0.0",
  "lockfileVersion": 2,
  "requires": true,
  "packages": {
    "": {
06:17:58
@gdamjan:spodeli.orggdamjanhttps://github.com/matrix-org/matrix-appservice-irc/releases/tag/1.0.109:14:11
@gdamjan:spodeli.orggdamjanall in all, I like the fetchYarnDeps + mkDerivation combo. less magic, more control, and it's not that hard at all09:30:37
@gdamjan:spodeli.orggdamjan

one question about https://github.com/NixOS/nixpkgs/pull/246188 … I have nodejs-slim in nativeBuildInputs, so that makes it depend on slim at runtime. Is this a good approach?


  nativeBuildInputs = [
    prefetch-yarn-deps
    nodejs-slim
    nodejs.pkgs.yarn
    nodejs.pkgs.node-gyp-build
  ];
09:34:26
@gdamjan:spodeli.orggdamjanalthough, nodejs-slim-18.16.1 still depends on icu4c-73.2-dev, openssl-3.0.9-dev, openssl-3.0.9-dev and zlib-1.2.13-dev :/ - not more than 10MB but still09:41:36
@lily:lily.flowersLily Foster
In reply to @robert:funklause.de

I get

Error: invalid HTTP request

Caused by:
    invalid format

when running prefetch-npm-deps on https://github.com/cloudflare/workers-sdk/blob/wrangler%403.3.0/package-lock.json
Is that because of the empty string key?

{
  "name": "wrangler-root",
  "version": "0.0.0",
  "lockfileVersion": 2,
  "requires": true,
  "packages": {
    "": {
It is not because of that. That is normal. I'll see if I can check sometime today but I'm betting there's a suspicious resolved uri
10:55:14
@lily:lily.flowersLily Foster
In reply to @gdamjan:spodeli.org

one question about https://github.com/NixOS/nixpkgs/pull/246188 … I have nodejs-slim in nativeBuildInputs, so that makes it depend on slim at runtime. Is this a good approach?


  nativeBuildInputs = [
    prefetch-yarn-deps
    nodejs-slim
    nodejs.pkgs.yarn
    nodejs.pkgs.node-gyp-build
  ];
I mean I guess if it works, sure. I don't know any downsides
10:56:16
@gdamjan:spodeli.orggdamjanworks for now :)10:57:32
@lily:lily.flowersLily FosterWait why would having it in nativeBuildInputs affect the runtime interpreter........11:02:07
@lily:lily.flowersLily FosterIs strictDeps on?11:02:45
@gdamjan:spodeli.orggdamjanbeats me11:02:46
@gdamjan:spodeli.orggdamjan
In reply to @lily:lily.flowers
Is strictDeps on?
no?
11:03:12
@lily:lily.flowersLily FosterAh then the separation of build-time and run-time inputs isn't enforced and it's assumed both are needed for both11:04:00
@lily:lily.flowersLily FosterDon't worry about it for now then. I'll test it with strictDeps on or just test cross and might ask it to be moved when reviewing your PR (sorry I didn't get to it yesterday...)11:04:49
@gdamjan:spodeli.orggdamjanno problem11:06:45
@gdamjan:spodeli.orggdamjanI'm probably gonna be offline for the better part of the day today. but I might get back online late in the evening (CEST evening that is)11:07:53
@gdamjan:spodeli.orggdamjan
In reply to @lily:lily.flowers
Ah then the separation of build-time and run-time inputs isn't enforced and it's assumed both are needed for both
but, how then yarn and node-gyp-build are NOT runtime dependencies?
11:16:07
@lily:lily.flowersLily FosterBecause they're only used for build. Nodejs is also needed for build but changing the build interpreter to change the runtine interpreter feels suspicious. But you have strictDeps off so that's probably why11:17:30
@gdamjan:spodeli.orggdamjanI wonder if node can be even removed from build deps11:18:19
@lily:lily.flowersLily FosterI think it technically can but I think that's because yarn currently hardcodes the nodejs path it uses11:20:09
@gdamjan:spodeli.orggdamjanright11:20:23
@lily:lily.flowersLily FosterBut if lifecycle scripts or something expects node or npm in path that it probably can't11:20:39
@gdamjan:spodeli.orggdamjanit seems that yarn updates the path with a /tmp/yarn--1690802924119-0.32849032875764905/ like directory that has node and yarn shell scripts11:30:00
@gdamjan:spodeli.orggdamjan just adding strictDeps = true; only removes bash from the immediate dependency :) 11:48:49
@gdamjan:spodeli.orggdamjanhttps://imgur.com/a/6jJ2AsX11:50:17

Show newer messages


Back to Room ListRoom Version: 6