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

lerna ERR! lerna WorkspaceContext is not a constructor #29304

Open
1 of 4 tasks
LiuLingyang opened this issue Dec 11, 2024 · 0 comments
Open
1 of 4 tasks

lerna ERR! lerna WorkspaceContext is not a constructor #29304

LiuLingyang opened this issue Dec 11, 2024 · 0 comments

Comments

@LiuLingyang
Copy link

LiuLingyang commented Dec 11, 2024

Current Behavior

after upgrading lerna 8.1.8,get an error when i run lerna command:

lerna ERR! TypeError: WorkspaceContext is not a constructor
lerna ERR! at setupWorkspaceContext (/Users/lanberts/Documents/create-next-app/node_modules/nx/src/utils/workspace-context.js:10:24)
lerna ERR! at ensureContextAvailable (/Users/lanberts/Documents/create-next-app/node_modules/nx/src/utils/workspace-context.js:50:9)
lerna ERR! at globWithWorkspaceContext (/Users/lanberts/Documents/create-next-app/node_modules/nx/src/utils/workspace-context.js:21:5)
lerna ERR! at retrieveProjectConfigurations (/Users/lanberts/Documents/create-next-app/node_modules/nx/src/project-graph/utils/retrieve-workspace-files.js:41:77)
lerna ERR! at buildProjectGraphAndSourceMapsWithoutDaemon (/Users/lanberts/Documents/create-next-app/node_modules/nx/src/project-graph/project-graph.js:77:98)
lerna ERR! at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
lerna ERR! at async createProjectGraphAndSourceMapsAsync (/Users/lanberts/Documents/create-next-app/node_modules/nx/src/project-graph/project-graph.js:201:25)
lerna ERR! at async createProjectGraphAsync (/Users/lanberts/Documents/create-next-app/node_modules/nx/src/project-graph/project-graph.js:190:39)
lerna ERR! at async detectProjects (/Users/lanberts/Documents/create-next-app/node_modules/lerna/dist/index.js:1563:25)
lerna ERR! lerna WorkspaceContext is not a constructor

Image

Expected Behavior

run lerna command without error

GitHub Repo

no repo

Steps to Reproduce

1.upgrade lerna 8.1.8
2.run lerna chagned
3.get the error above

Nx Report

yarn:1.22.22 
node: 18.20.3
macOS: 10.14.3

Failure Logs

Package Manager Version

No response

Operating System

  • macOS
  • Linux
  • Windows
  • Other (Please specify)

Additional Information

No response

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

1 participant