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]: Error: @swc/types@workspace:^: Workspace not found #27385

Closed
valentinpalkovic opened this issue May 28, 2024 · 1 comment
Closed

[Bug]: Error: @swc/types@workspace:^: Workspace not found #27385

valentinpalkovic opened this issue May 28, 2024 · 1 comment

Comments

@valentinpalkovic
Copy link
Contributor

valentinpalkovic commented May 28, 2024

Describe the bug

The latest @swc/core release is borked. The issue is partially fixed by tagging a previous version of @swc/core as latest. Though, some dependencies like @storybook/test-runner define a version range for @swc/core which will try to install the latest published version.

The issue can be tracked here: swc-project/swc#8988

Workaround

Please use your package manager's overrides capabilities to pin the @swc/core version until the issue is fixed upstream.

Use the overrides field for npm/pnpm:

// package.json
{
  ...
  overrides: {
    "@swc/core": "1.5.7"
  }  
}

Use the resolutions field for yarn:

// package.json
{
  ...
  resolutions: {
    "@swc/core": "1.5.7"
  }  
}
@valentinpalkovic
Copy link
Contributor Author

v1.5.22 has been released of @swc/core, which fixes the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants