| 17 Jan 2024 |
Lily Foster | err wait, no maybe i haven't found the bug. that didn't work. give me a few | 23:20:45 |
h7x4 | No worries 😄 Ping me if you'd like the package file with the current failing setup. | 23:23:45 |
Lily Foster | In reply to @h7x4:nani.wtf No worries 😄 Ping me if you'd like the package file with the current failing setup. sure, i made my own super quickly but that would probably help too | 23:25:48 |
Lily Foster | i'm starting to wonder if this is just an npm bug? at least in my reproducer, it has nothing to do with lockfile fixup afaict | 23:30:04 |
Lily Foster | npm says "tarball data seems to be corrupted" even though hash matches and the tarball seems valid 🤔 | 23:30:38 |
h7x4 | I've bundled a patch, likely introducing IFD, but good enough for testing.
{ lib
, buildNpmPackage
, fetchNpmDeps
, fetchFromGitea
, git
, cacert
, writeText
}:
# Smaller version of the problem
# fetchNpmDeps {
# name = "out-of-your-element-deps";
# src = fetchFromGitea {
# domain = "gitdab.com";
# owner = "cadence";
# repo = "out-of-your-element";
# rev = "v1.3";
# hash = "sha256-dLDm3xOMoprkGU7D9IFX1hjMfCR3YjVgXb3c5IEuUTQ";
# };
# patches = [ ./add-discord-markdown-dep-integrity.patch ];
# npmDepsHash = "sha256-k2MeejRWteIzY1Q+iNLCLDLnE1z9+cBaAGYAIlQHa/4=";
# };
buildNpmPackage rec {
pname = "out-of-your-element";
version = "1.3";
src = fetchFromGitea {
domain = "gitdab.com";
owner = "cadence";
repo = "out-of-your-element";
rev = "v${version}";
hash = "sha256-dLDm3xOMoprkGU7D9IFX1hjMfCR3YjVgXb3c5IEuUTQ";
};
patches = [ (writeText "add-discord-markdown-dep-integrity.patch" ''
diff --git i/package-lock.json w/package-lock.json
index 3847ee1..79a3ac0 100644
--- i/package-lock.json
+++ w/package-lock.json
@@ -1060,6 +1060,7 @@
"node_modules/discord-markdown": {
"version": "2.4.1",
"resolved": "git+https://git.sr.ht/~cadence/nodejs-discord-markdown#abc56d544072a1dc5624adfea455b0e902adf7b3",
+ "integrity": "sha512-mPjPXXNgL3prKagvj/guOzAEMcJdcr6S95u7MRlYZvsgeUiacQDQatYrJgYAf53vJw+U0JvEPUwRHZY02oX1og==",
"license": "MIT",
"dependencies": {
"simple-markdown": "^0.7.2"
'') ];
dontNpmBuild = true;
npmDepsHash = "sha256-fPTFyX2GYSdMeIzVKXBacZxhTTj8fvlMFEGOxN0/cm8=";
meta = with lib; {
homepage = "https://gitdab.com/cadence/out-of-your-element";
description = "Modern Matrix-to-Discord appservice bridge";
changelog = "https://gitdab.com/cadence/out-of-your-element/releases/tag/${src.rev}";
license = licenses.agpl3Plus;
mainProgram = "start.js";
};
}
| 23:34:11 |
Lily Foster | gods i wish npm's debug logging wasn't so slim and convenient not say where or why the error actually happened... | 23:57:46 |
Lily Foster | * gods i wish npm's debug logging wasn't so slim and not say where or why the error actually happened... | 23:57:55 |
| 18 Jan 2024 |
| @syntheit:matrix.org left the room. | 04:14:31 |
| 19 Jan 2024 |
| @ThorHop:matrix.org changed their display name from hopland (meticulous montesquieu) to hopland (manners or stfu). | 05:12:19 |
| @ThorHop:matrix.org changed their display name from hopland (manners or stfu) to hopland. | 05:14:42 |
| 22 Jan 2024 |
szucsitg | What is the right way to not copy node_modules into lib folder with buildNpmPackage? As it's a static frontend code it doesn't need that folder at all | 09:37:28 |
szucsitg | Ah, I guess I should have just added dontInstall = true 😅 | 09:51:24 |
Marie | you could also set installPhase for copying the build output to $out | 10:36:20 |
| @ThorHop:matrix.org changed their display name from hopland to IdeallyYes. | 15:06:40 |
| 29 Jan 2024 |
hexa | Redacted or Malformed Event | 22:31:06 |
hexa | fetchNpmDeps chokes on fetching cryptpad things 😄 | 22:31:33 |
hexa | this looks an issue avocadoom solved by exporting HOME, but since it happens in the fetcher for me....? | 22:32:00 |
hexa | * this looks an issue avocadoom solved by exporting HOME | 22:37:19 |
hexa | * fetchNpmDeps chokes on cryptpad things 😄 | 22:37:43 |
hexa | * buildNpmPackage chokes on cryptpad things 😄 | 22:37:49 |
hexa | but doing that doesn't help 🙂 | 22:44:13 |