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

Solve peer-dependency warnings on pnpm install #3208

Closed
cindyledev opened this issue Mar 14, 2022 · 0 comments · Fixed by #3284
Closed

Solve peer-dependency warnings on pnpm install #3208

cindyledev opened this issue Mar 14, 2022 · 0 comments · Fixed by #3284
Assignees
Labels
area: docusaurus Anything related to Docusaurus area: front-end dependencies Pull requests that update a dependency file developer experience Helping the Developer Experience type: enhancement New feature or request type: nice to have Feature that'd be nice to have, but not a priority
Milestone

Comments

@cindyledev
Copy link
Contributor

cindyledev commented Mar 14, 2022

In addition to the deprecation warnings mentioned in #3177, we have warnings about missing peer-dependencies

 WARN  Issues with peer dependencies found
.
├─┬ @typescript-eslint/eslint-plugin
│ ├── ✕ missing peer typescript@"*"
│ ├── ✕ missing peer eslint@"^5.0.0 || ^6.0.0 || ^7.0.0"
│ └─┬ @typescript-eslint/experimental-utils
│   ├── ✕ missing peer eslint@"*"
│   ├─┬ @typescript-eslint/typescript-estree
│   │ ├── ✕ missing peer typescript@"*"
│   │ └─┬ tsutils
│   │   └── ✕ missing peer typescript@">=2.8.0 || >= 3.2.0-dev || >= 3.3.0-dev || >= 3.4.0-dev || >= 3.5.0-dev || >= 3.6.0-dev || >= 3.6.0-beta || >= 3.7.0-dev || >= 3.7.0-beta"
│   └─┬ eslint-utils
│     └── ✕ missing peer eslint@>=5
├─┬ @typescript-eslint/parser
│ ├── ✕ missing peer typescript@"*"
│ └── ✕ missing peer eslint@"^5.0.0 || ^6.0.0 || ^7.0.0"
├─┬ ts-jest
│ └── ✕ missing peer typescript@">=3.8 <5.0"
├─┬ jest-playwright-preset
│ ├── ✕ missing peer jest-circus@>=26.6.3
│ ├── ✕ missing peer jest-environment-node@>=26.6.3
│ └── ✕ missing peer jest-runner@>=26.6.3
└─┬ ioredis-mock
  └── ✕ missing peer redis-commands@1.x
Peer dependencies that should be installed:
  eslint@">=5.0.0 <6.0.0 || >=6.0.0 <7.0.0 || >=7.0.0 <8.0.0"  jest-environment-node@>=26.6.3                               redis-commands@1.x                                           
  jest-circus@>=26.6.3                                         jest-runner@>=26.6.3                                         typescript@">=3.8.0 <5.0.0"                                  

src/api/posts
└─┬ ioredis-mock
  └── ✕ missing peer redis-commands@1.x
Peer dependencies that should be installed:
  redis-commands@1.x  

src/docs
├─┬ @docusaurus/core
│ └─┬ react-dev-utils
│   └─┬ fork-ts-checker-webpack-plugin
│     └── ✕ missing peer typescript@">= 2.7"
├─┬ @docusaurus/preset-classic
│ ├─┬ @docusaurus/plugin-debug
│ │ └─┬ react-json-view
│ │   └─┬ react-textarea-autosize
│ │     └─┬ use-latest
│ │       ├── ✕ missing peer @types/react@"*"
│ │       └─┬ use-isomorphic-layout-effect
│ │         └── ✕ missing peer @types/react@"*"
│ └─┬ @docusaurus/theme-search-algolia
│   └─┬ @docsearch/react
│     ├── ✕ missing peer @types/react@">= 16.8.0 < 18.0.0"
│     └─┬ @algolia/autocomplete-preset-algolia
│       └── ✕ missing peer @algolia/client-search@^4.9.1
└─┬ mdx-mermaid
  ├── ✕ missing peer unist-util-visit@^2.0.0
  └── ✕ unmet peer mermaid@">= 8.11.0 < 8.12.0": found 8.14.0
Peer dependencies that should be installed:
  @algolia/client-search@^4.9.1    @types/react@">=16.8.0 <18.0.0"  typescript@">= 2.7"              unist-util-visit@^2.0.0          

src/web
├─┬ babel-loader
│ └── ✕ missing peer webpack@>=2
├─┬ terser-webpack-plugin
│ └── ✕ missing peer webpack@^5.1.0
└─┬ next-pwa
  ├─┬ clean-webpack-plugin
  │ └── ✕ missing peer webpack@">=4.0.0 <6.0.0"
  └─┬ workbox-webpack-plugin
    └── ✕ missing peer webpack@"^4.4.0 || ^5.9.0"
Peer dependencies that should be installed:
  webpack@">=5.9.0 <6.0.0"  

Adding this to .npmrc in root only installs missing peer dependencies when we add new dependencies. It does not take care of the missing peer dependencies we currently have.

# pnpm add <pkg> automatically installs any missing peer dependencies as dev dependencies
auto-install-peers=true

Note: Depending on your OS, you may or may not even see these warnings. I get these warnings using AWS EC2 Amazon Linux 2 AMI. Also if you do not see the errors on the master branch, try deleting the pnpm-lock.yaml file.

@cindyledev cindyledev added the type: bug Something isn't working label Mar 14, 2022
@cindyledev cindyledev self-assigned this Mar 14, 2022
@cindyledev cindyledev added dependencies Pull requests that update a dependency file type: nice to have Feature that'd be nice to have, but not a priority and removed type: bug Something isn't working labels Mar 14, 2022
@cindyledev cindyledev added this to the 2.9 Release milestone Mar 14, 2022
@cindyledev cindyledev added type: enhancement New feature or request area: front-end developer experience Helping the Developer Experience parent issue area: docusaurus Anything related to Docusaurus labels Mar 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: docusaurus Anything related to Docusaurus area: front-end dependencies Pull requests that update a dependency file developer experience Helping the Developer Experience type: enhancement New feature or request type: nice to have Feature that'd be nice to have, but not a priority
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant