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

Cannot find package error when using auto-install #9201

Open
sigmaSd opened this issue Mar 2, 2024 · 1 comment
Open

Cannot find package error when using auto-install #9201

sigmaSd opened this issue Mar 2, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@sigmaSd
Copy link

sigmaSd commented Mar 2, 2024

What version of Bun is running?

1.0.29

What platform is your computer?

linux

What steps can reproduce the bug?

import { Magika } from "magika@0.2.5";
const magika = new Magika();

What is the expected behavior?

no error

What do you see instead?

error

error: Cannot find package "long" from "/home/mrcool/.bun/install/cache/@tensorflow/tfjs@4.17.0/dist/tf.node.js"

Additional information

No response

@sigmaSd sigmaSd added the bug Something isn't working label Mar 2, 2024
@Jarred-Sumner Jarred-Sumner changed the title error using a module Cannot find package error when using auto-install Mar 2, 2024
@evgenyt1
Copy link

evgenyt1 commented Jul 19, 2024

I've got similar issues with auto-install in 1.1.20.

For me

  • windows:
C:\Users\user1\projects>bun run index.js
error: Unexpected while resolving package "cowsay" from "C:\Users\user1\projects\index.js"
  • macos (arm):
➜  123 bun run index.js
error: Cannot find package "cowsay" from "/Users/user1/tmp/123/index.js"
  • linux works

No node_modules or package.json. index.js everywhere the same.:

import { say } from "cowsay";
console.log(say({ text: "grazing in the browser" }));

Just wondering if auto-install ever worked on macos? I’ve tried downgrading to a few older versions to check - doesn't work for me

UPDATE:
It looks it has something to do with my system/user on macOS. Another user created on the same machine has auto-import working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants