fix: pin mime@^1.6.0 via pnpm override
Some checks are pending
Build / native (push) Waiting to run
Build / nix (push) Waiting to run

@astrojs/node 8.3.4 pulls in send@0.19.1, which calls mime.lookup().
mime moved that method to mime.getType() in v3+. With pnpm hoisting,
mime@4 sometimes shadows the transitive mime@1 send expects, and the
server crashes on the first static-asset request with
'TypeError: mime.lookup is not a function'.
This commit is contained in:
Ryan Malloy 2026-06-06 13:11:58 -06:00
parent 7c21720519
commit 0b8812d864
2 changed files with 11 additions and 11 deletions

View File

@ -1,7 +1,7 @@
{
"name": "heady",
"version": "1.0.0",
"description": "🤠 Heady - Strategic VPN management that's actually awesome to use!",
"description": "\ud83e\udd20 Heady - Strategic VPN management that's actually awesome to use!",
"type": "module",
"private": true,
"scripts": {
@ -87,6 +87,9 @@
"better-sqlite3",
"esbuild",
"lefthook"
]
],
"overrides": {
"mime": "^1.6.0"
}
}
}

15
pnpm-lock.yaml generated
View File

@ -4,6 +4,9 @@ settings:
autoInstallPeers: true
excludeLinksFromLockfile: false
overrides:
mime: ^1.6.0
importers:
.:
@ -57,8 +60,8 @@ importers:
specifier: ^0.456.0
version: 0.456.0
mime:
specifier: ^4.0.7
version: 4.0.7
specifier: ^1.6.0
version: 1.6.0
openid-client:
specifier: 6.7.0
version: 6.7.0
@ -3024,11 +3027,6 @@ packages:
engines: {node: '>=4'}
hasBin: true
mime@4.0.7:
resolution: {integrity: sha512-2OfDPL+e03E0LrXaGYOtTFIYhiuzep94NSsuhrNULq+stylcJedcHdzHtz0atMUuGwJfFYs0YL5xeC/Ca2x0eQ==}
engines: {node: '>=16'}
hasBin: true
mimic-function@5.0.1:
resolution: {integrity: sha512-VP79XUPxV2CigYP3jWwAUFSku2aKqBH7uTAapFWCBqutsbmDo96KY5o8uh6U+/YSIn5OxJnXp73beVkpqMIGhA==}
engines: {node: '>=18'}
@ -3308,6 +3306,7 @@ packages:
prebuild-install@7.1.3:
resolution: {integrity: sha512-8Mf2cbV7x1cXPUILADGI3wuhfqWvtiLA1iclTDbFRZkgRQS0NqsPZphna9V+HyTEadheuPmjaJMsbzKQFOzLug==}
engines: {node: '>=10'}
deprecated: No longer maintained. Please contact the author of the relevant native addon; alternatives are available.
hasBin: true
preferred-pm@4.1.1:
@ -7175,8 +7174,6 @@ snapshots:
mime@1.6.0: {}
mime@4.0.7: {}
mimic-function@5.0.1: {}
mimic-response@3.1.0: