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

🐛 BUG: Vitest: runInDurableObject() fails if package.json contains a namespace (e.g. @repo/my-worker) #6954

Open
jahands opened this issue Oct 12, 2024 · 0 comments
Labels
bug Something that isn't working

Comments

@jahands
Copy link
Contributor

jahands commented Oct 12, 2024

Which Cloudflare product(s) does this pertain to?

Workers Vitest Integration

What version(s) of the tool(s) are you using?

[email protected], @cloudflare/[email protected]

What version of Node are you using?

22.9.0

What operating system and version are you using?

Mac Sonoma 14.6.1

Describe the Bug

Observed behavior

Tests fail when using runInDurableObject() when package.json contains a namespace in the name field (e.g. @repo/worker-a instead of worker-a.)

Note: adding a namespace like @repo/ to packages is useful in monorepos for tools like syncpack where I want to treat all @repo/ packages as local.

Expected behavior

Tests pass

Steps to reproduce

git clone https://github.com/jahands/cf-vitest-pkg-name-error.git
cd cf-vitest-pkg-name-error
pnpm install
pnpm test

Please provide a link to a minimal reproduction

https://github.com/jahands/cf-vitest-pkg-name-error

Please provide any relevant error logs

See repo README

@jahands jahands added the bug Something that isn't working label Oct 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something that isn't working
Projects
Status: Untriaged
Development

No branches or pull requests

1 participant