PANE

Bun package installations fail when using custom registries

20 posts since Sep 2023, all from GitHub.

“What is the problem this feature would solve? When running bun install with a URL, servers that resolve the same URL differently for different types of requests could check for the useragent npm to resolve in an npm like manner. In my tests, this is what npm, pnpm, and yarn do…”
GitHub
“What version of Bun is running? 1.4.4+38afee6c8 What platform is your computer? Darwin 27.0.0 arm64 arm What steps can reproduce the bug? Then run Bun.serve with development.hmr = true . index.ts foo.ts What is the expected behavior? Only foo should be updated. What do you see…”
GitHub
“What version of Bun is running? 1.4.3 (also 1.3.14) What platform is your computer? Darwin 25.6.0 arm64 What steps can reproduce the bug? What is the expected behavior? bun patch ms@2.1.3 finds the aliased install, since patchedDependencies is keyed on the real name and version…”
GitHub

Users are encountering issues with Bun's package installation process when using custom registries. The problems range from incorrect URL trimming to authentication failures, hindering the ability to install scoped private packages.

devtoolstoolingpackage-managementjavascripttypescript
FIT
0%
SIGNAL
67%
SOURCES20
FRESHEST POSTOCT 29
TRACKED SINCE49D AGO

SOURCES (20)

“What version of Bun is running? 1.4.4+38afee6c8 What platform is your computer? Darwin 27.0.0 arm64 arm What steps can reproduce the bug? Then run Bun.serve with development.hmr = true . index.ts foo.ts What is the expected behavior? Only foo should be updated. What do you…”

GITHUBOct 29

“What version of Bun is running? 1.4.4+38afee6c8 What platform is your computer? Linux 7.0.12 linuxkit aarch64 unknown , in Docker on an Apple M4. Bun runs under qemu aarch64 10.0.13 (user mode emulation). What steps can reproduce the bug? A minimal React Router app. Create these files in one directory: package.json vite.config.js app/root.jsx app/routes.js gen.mjs run.sh Then run: What is the expected behavior? All 6 builds complete ( build 1: done … build 6: done ), as they do with Bun 1.3.14.”

GITHUBOct 23

“What version of Bun is running? 1.4.3 (also 1.3.14) What platform is your computer? Darwin 25.6.0 arm64 What steps can reproduce the bug? What is the expected behavior? bun patch ms@2.1.3 finds the aliased install, since patchedDependencies is keyed on the real name and version. Failing that, the error should say the package is installed under an alias and name the alias. What do you see instead? error: package ms@2.1.3 not found , although ms@2.1.3 is installed (as ms alias ) and bun patch comm”

GITHUBOct 16

“What version of Bun is running? 1.3.14+0d9b296af What platform is your computer? Linux, Bitbucket pipelines What steps can reproduce the bug? Given you have a bunfig.toml with And installed the security scanner as a dev dependency using When you run Then the install fails with error What is the expected behavior? When the production flag is used, and the package will not be installed, I do not expect an error. I understand this might be tricky. Alternatively, the frozen lockfile + production fla”

GITHUBMay 19

“What version of Bun is running? 1.3.11 What platform is your computer? No response What steps can reproduce the bug? Using offical bun docker image docker.io/oven/bun:1.3.11 alpine Try to run bun install with .npmrc that uses scoped private packages. Eksample TOKENS seams not to be passed in or used correctly in 1.3.11 but the same config works in 1.3.10 Could be related to .npmrc fix in 1.3.11 https://bun.com/blog/bun v1.3.11 bun install Fixed: .npmrc auth token matching only comparing hostname”

GITHUBMar 18

“What version of Bun is running? 1.3.5+1e86cebd7 What platform is your computer? Darwin 25.2.0 arm64 arm What steps can reproduce the bug? While testing bun install , I noticed that although package metadata is fetched from the configured npm registry, tarball downloads appear to be fetched directly from their resolved URLs rather than being routed through the registry. With npm, tarball requests are typically proxied or rewritten through the registry, which allows private registries, mirrors, or”

GITHUBJan 11
Source preview · github.com

What version of Bun is running? 1.3.1+89fa0f343 What platform is your computer? Darwin 25.0.0 arm64 arm What steps can reproduce the bug? Run this command in an empty project: Installation fails with…

github.comOct 2025

“What version of Bun is running? 1.3.0+b0a6feca5 What platform is your computer? Linux 6.17.3 arch2 1 x86 64 unknown What steps can reproduce the bug? i ran bun init and select the tailiwnd + shadcn full stack template added tanstack router and configured it in the app.tsx pacakges installed bun add @tanstack/react router @tanstack/react router devtools bun add D @tanstack/router plugin bun add D @tanstack/router cli followed the standard manual setup + cli cli to watch and generate routes automa”

GITHUBOct 2025

“What version of Bun is running? 1.2.21+7c45ed97d What platform is your computer? Linux 4.14.355 277.647.amzn2.aarch64 aarch64 aarch64 What steps can reproduce the bug? I'm using an AWS CodeBuild instance, and I do: curl fsSL https://bun.com/install | bash s "bun v1.2.21" export BUN INSTALL="$HOME/.bun" export PATH="$BUN INSTALL/bin:$PATH" bun install ignore scripts config=bunfig.toml Here is my bunfig file: And I got 401 errors during installation, but if I do it in my local setup (macOS), it wo”

GITHUBSep 2025

“What version of Bun is running? 1.2.5 canary.70+8a177f6c8 What platform is your computer? Darwin 24.3.0 arm64 arm What steps can reproduce the bug? Set up a Bun + React web app with HTML imports and HMR. 1. Bun.serve with routes 2. import index from './index.html 3. routes: { '/': index } 4. bun add react react dom 5. <script src="index.tsx" </script 6. import React from 'react ; import ReactDOM from 'react dom/client ; ReactDOM.render(document.body, <App / 7. export default function App() { ret”

GITHUBMar 2025

“What version of Bun is running? 1.2.2+c1708ea6a What platform is your computer? Linux 6.12.11 1 lts x86 64 unknown What steps can reproduce the bug? package.json: bunfig.toml: Run bun install . What is the expected behavior? yarn.lock generated by yarn v1: What do you see instead? yarn.lock: yarn output: Additional information No response”

GITHUBFeb 2025

“What version of Bun is running? 1.1.26 What platform is your computer? x64 What steps can reproduce the bug? Add under / dir a .bunfig.toml file like this: Then: bun install What is the expected behavior? When running bun install , I should see the url used to fetch the libs (react for example) as: https://www.my repo/npm enterprise/react What do you see instead? I see the url to fetch react as: https://www.my repo/react Additional information Adding a trailing forward slash to the url fixes the”

GITHUBSep 2024

“What version of Bun is running? 1.0.16+800fb1290 What platform is your computer? Linux 6.2.0 37 generic x86 64 x86 64 What steps can reproduce the bug? Setting up a private package in the NPM registry Config the bunfig.toml run "bun install" What is the expected behavior? A full install of private packages What do you see instead? error: FailedToOpenSocket downloading package manifest @myOrg/storybook error: @myOrg/storybook@^0.1.22 failed to resolve Additional information This is my bunfile.tom”

GITHUBDec 2023

“What version of Bun is running? 1.0.14+d8be3e51b What platform is your computer? (Debian) Linux 6.1.0 13 amd64 x86 64 unknown What steps can reproduce the bug? When sending ID and password: It does send the request, but does not send an authorization header. When sending only ID: From the error log, it seems to be corrupting the URL itself: http://user@localhost:5000/pkg@http://user@localhost:5000/pkg What is the expected behavior? Bun must send authorization header by encoding the user:password”

GITHUBDec 2023

“What is the problem this feature would solve? When running bun install with a URL, servers that resolve the same URL differently for different types of requests could check for the useragent npm to resolve in an npm like manner. In my tests, this is what npm, pnpm, and yarn do: Bun sends this: What is the feature you are proposing to solve the problem? Bun could definitely add npm/? linux x64 to the user agent string. This would give enough information for the server to deliver the correct packa”

GITHUBDec 2023

“What version of Bun is running? 1.0.14 What platform is your computer? mac, m1 What steps can reproduce the bug? Create package.json with internal and external packages: .npmrc: i found in documentation that bun.js supports scopes, but as far as I understand scopes is like @types and my internal package: mypackage no scoped? i tried multiple ways, but nothing really works, this is just one of examples: npm.example.com server doesn't have proxy mode or redirect to public npm if something is not f”

GITHUBNov 2023

“What version of Bun is running? 1.0.4+745b6b94ee56cad24d475799690cc9a89957d15b What platform is your computer? Linux 6.2.0 31 generic x86 64 x86 64 What steps can reproduce the bug? Try running bun pm cache rm g from directory which doesn't belong to bun project What is the expected behavior? deletes the cache directory. What do you see instead? <img width="430" alt="image" src="https://github.com/oven sh/bun/assets/120368959/d8ae90f7 d7bd 4994 bb88 5e460b2d404e" Additional information bun pm ca”

GITHUBOct 2023

“What version of Bun is running? 1.0.4 What platform is your computer? Docker: debian:stable slim What steps can reproduce the bug? I incapsulated Bun to our development workflow in Docker image, and it went fine at first, but now it fails to install from https://bun.sh/install. Dockerfile instruction: What is the expected behavior? Bun successfully installs. What do you see instead? Result: Additional information Seems like you’re protecting https://bun.sh/install URL with CloudFlare and it’s bl”

GITHUBOct 2023

“What version of Bun is running? 0.8.1 What platform is your computer? Darwin 21.6.0 x86 64 i386 Linux 6.4.12 arch1 1 x86 64 unknown What steps can reproduce the bug? Create a config file with something like the following: Install a global package like: bun config=/path/to/config.toml add g prettier What is the expected behavior? Bun should install the package to /.bun alt . What do you see instead? Bun installs the package to the default directory, /.bun . Additional information No response”

GITHUBSep 2023
Source preview · github.com
https://github.com/oven-sh/bun/issues/8
github.com

SOLUTION LANDSCAPE

Brought to you byTop Sectors

A Player feature.See how many ways this pain can be solved, who's already building, and where the gaps are.

Related panes

/ same corner of the problem