Skip to content

Instantly share code, notes, and snippets.

@waptik
Created January 4, 2024 22:48
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save waptik/595e33318d49559fe09ee618825078e2 to your computer and use it in GitHub Desktop.
Save waptik/595e33318d49559fe09ee618825078e2 to your computer and use it in GitHub Desktop.
cli error message for @turbo/workspaces package when migrating from yarn to pnpm
>>> TURBOREPO
Welcome, let's convert your project.
? Where is the root of your repo? .
? Convert from yarn workspaces to: pnpm workspaces
Converting project from yarn to pnpm.
1. Removing yarn workspaces from notionbird
- OK | removing "workspaces" field in notionbird root "package.json"
- OK | removing "packageManager" field in notionbird root "package.json"
- OK | removing "node_modules"
2. Adding pnpm workspaces to notionbird
Root:
- OK | adding "packageManager" field to notionbird root "package.json"
- OK | adding "pnpm-workspace.yaml"
- OK | no workspace dependencies found in ./package.json
Workspaces:
- OK | updating 3 dependencies, and 2 devDependencies in ./apps/web/package.json
- OK | no workspace dependencies found in ./packages/config/package.json
- OK | no workspace dependencies found in ./packages/dayjs/package.json
- OK | updating 3 dependencies in ./packages/features/package.json
- OK | updating 1 devDependencies in ./packages/lib/package.json
- OK | updating 1 dependencies in ./packages/prisma/package.json
- OK | no workspace dependencies found in ./packages/trpc/package.json
- OK | no workspace dependencies found in ./packages/tsconfig/package.json
- OK | no workspace dependencies found in ./packages/types/package.json
3. Installing dependencies
- OK | converting yarn.lock to pnpm-lock.yaml
- OK | running "pnpm install --fix-lockfile"
- OK | installing dependencies... - ERROR | failed to install dependencies
Unexpected error. Please report it as a bug:
Error: Command failed with exit code 1: pnpm install --fix-lockfile
Scope: all 10 workspace projects
╭──────────────────────────────────────────────────────────────────╮
│ │
│ Update available! 8.12.1 → 8.14.0. │
│ Changelog: https://github.com/pnpm/pnpm/releases/tag/v8.14.0 │
│ Run "pnpm add -g pnpm" to update. │
│ │
│ Follow @pnpmjs for updates: https://twitter.com/pnpmjs │
│ │
╰──────────────────────────────────────────────────────────────────╯
Progress: resolved 0, reused 1, downloaded 0, added 0
Progress: resolved 609, reused 596, downloaded 0, added 0
Progress: resolved 1076, reused 1063, downloaded 0, added 0
Progress: resolved 1077, reused 1064, downloaded 0, added 0
Packages: +1065
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Progress: resolved 1077, reused 1064, downloaded 0, added 272
Progress: resolved 1077, reused 1064, downloaded 0, added 874
Progress: resolved 1077, reused 1064, downloaded 0, added 1065, done
. postinstall$ turbo run post-install
. postinstall: • Packages in scope: @notionbird/config, @notionbird/dayjs, @notionbird/features, @notionbird/lib, @notionbird/prisma, @notionbird/trpc, @notionbird/tsconfig, @notionbird/types, @notionbird/web
. postinstall: • Running post-install in 9 packages
. postinstall: • Remote caching disabled
. postinstall: @notionbird/prisma:post-install: cache bypass, force executing 6feb0ac7a3fcb047
. postinstall: @notionbird/prisma:post-install:
. postinstall: @notionbird/prisma:post-install: > @notionbird/prisma@0.0.0 post-install /workspace/notionbird.com/packages/prisma
. postinstall: @notionbird/prisma:post-install: > yarn db-generate
. postinstall: @notionbird/prisma:post-install:
. postinstall: @notionbird/prisma:post-install: Usage Error: The nearest package directory (/workspace/notionbird.com/packages/prisma) doesn't seem to be part of the project declared in /workspace/notionbird.com.
. postinstall: @notionbird/prisma:post-install:
. postinstall: @notionbird/prisma:post-install: - If /workspace/notionbird.com isn't intended to be a project, remove any yarn.lock and/or package.json file there.
. postinstall: @notionbird/prisma:post-install: - If /workspace/notionbird.com is intended to be a project, it might be that you forgot to list packages/prisma in its workspace configuration.
. postinstall: @notionbird/prisma:post-install: - Finally, if /workspace/notionbird.com is fine and you intend packages/prisma to be treated as a completely separate project (not even a workspace), create an empty yarn.lock file in it.
. postinstall: @notionbird/prisma:post-install:
. postinstall: @notionbird/prisma:post-install: $ yarn run [--inspect] [--inspect-brk] [-T,--top-level] [-B,--binaries-only] <scriptName> ...
. postinstall: @notionbird/prisma:post-install:  ELIFECYCLE  Command failed with exit code 1.
. postinstall: @notionbird/prisma:post-install: ERROR: command finished with error: command (/workspace/notionbird.com/packages/prisma) pnpm run post-install exited (1)
. postinstall: command (/workspace/notionbird.com/packages/prisma) pnpm run post-install exited (1)
. postinstall: ERROR run failed: command exited (1)
. postinstall: Tasks: 0 successful, 1 total
. postinstall: Cached: 0 cached, 1 total
. postinstall: Time: 1.133s
. postinstall: Failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment