Seneca-CDOT / telescope

A tool for tracking blogs in orbit around Seneca's open source involvement
https://telescope.cdot.systems
BSD 2-Clause "Simplified" License
96 stars 189 forks source link

Solve deprecation warnings on pnpm install #3177

Open humphd opened 2 years ago

humphd commented 2 years ago
$ pnpm install
src/api/posts                            |  WARN  deprecated superagent@6.1.0
src/api/posts                            |  WARN  deprecated formidable@1.2.6
src/docs                                 |  WARN  deprecated querystring@0.2.1
src/docs                                 |  WARN  deprecated @braintree/sanitize-url@3.1.0g registry.npmjs.org/typescript/4.4.4: 3.16 MB/11 MB
tools/autodeployment                     |  WARN  deprecated uuid@3.4.0
tools/autodeployment                     |  WARN  deprecated uuid@3.4.0
tools/autodeployment                     |  WARN  deprecated uuid@3.4.0
 WARN  deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
src/docs                                 |  WARN  deprecated querystring@0.2.0
src/web                                  |  WARN  deprecated source-map-url@0.4.1ownloading registry.npmjs.org/typescript/4.4.4: 8.33 MB/11 MB
src/web
...
cindyorangis commented 2 years ago

Interesting to see we have different outputs after running pnpm install in root. I'm using Windows 10

PS C:\Users\lecin\Documents\repo\telescope> pnpm install
Scope: all 16 workspace projects
src/web                                  |  WARN  deprecated @material-ui/core@4.12.3
src/api/posts                            |  WARN  src\api\posts: ioredis-mock@5.9.1 requires a peer of redis-commands@1.x but none was installed.
src/docs                                 |  WARN  src\docs > @docusaurus/core > react-dev-utils: fork-ts-checker-webpack-plugin@6.5.0 requires a peer of typescript@>= 2.7 but none was installed.
src/docs                                 |  WARN  src\docs > @docusaurus/preset-classic > @docusaurus/theme-search-algolia > @docsearch/react: @algolia/autocomplete-preset-algolia@1.5.2 requires a peer of @algolia/client-search@^4.9.1 but none 
was installed.
src/docs                                 |  WARN  src\docs > @docusaurus/preset-classic > @docusaurus/theme-search-algolia: @docsearch/react@3.0.0 requires a peer of @types/react@>= 16.8.0 < 18.0.0 but none was installed.
src/docs                                 |  WARN  src\docs: mdx-mermaid@1.2.1 requires a peer of mermaid@>= 8.11.0 < 8.12.0 but version 8.14.0 was installed.
 WARN  15 other warnings
Already up-to-date
Progress: resolved 1569, reused 1528, downloaded 0, added 0, done
cindyorangis commented 2 years ago

I ran pnpm outdated -r --long in the root to check for all the outdated dependencies but I can't get the same warnings mentioned in opening issue

These are the only deprecated dependencies I see.

┌────────────────────────────────────────┬──────────┬────────────┬────────────────────────────────┬───────────────────────────────────────────────────────────────────────────────────────┐
│ Package                                │ Current  │ Latest     │ Dependents                     │ Details                                                                               │
├────────────────────────────────────────┼──────────┼────────────┼────────────────────────────────┼───────────────────────────────────────────────────────────────────────────────────────┤
│ @material-ui/core                      │ 4.12.3   │ Deprecated │ @senecacdot/telescope-frontend │ You can now upgrade to @mui/material.                                                 │
│                                        │          │            │                                │ See the guide:                                                                        │
│                                        │          │            │                                │ https://mui.com/guides/migration-v4/                                                  │
│                                        │          │            │                                │ https://material-ui.com/                                                              │
├────────────────────────────────────────┼──────────┼────────────┼────────────────────────────────┼───────────────────────────────────────────────────────────────────────────────────────┤
│ @material-ui/icons                     │ 4.11.2   │ Deprecated │ @senecacdot/telescope-frontend │ You can now upgrade to @mui/icons. See                                                │
│                                        │          │            │                                │ the guide:                                                                            │
│                                        │          │            │                                │ https://mui.com/guides/migration-v4/                                                  │
│                                        │          │            │                                │ https://github.com/mui-org/material-ui/tree/master/packages/material-ui-icons         │
├────────────────────────────────────────┼──────────┼────────────┼────────────────────────────────┼───────────────────────────────────────────────────────────────────────────────────────┤

I've also tried pnpm install --ignore-scripts --reporter=append-only

src/web                                  |  WARN  deprecated @material-ui/core@4.12.3
src/web                                  |  WARN  deprecated @material-ui/icons@4.11.2
src/api/posts                            |  WARN  src\api\posts: ioredis-mock@5.9.1 requires a peer of redis-commands@1.x but none was installed.
src/docs                                 |  WARN  src\docs > @docusaurus/core > react-dev-utils: fork-ts-checker-webpack-plugin@6.5.0 requires a peer of typescript@>= 2.7 but none was installed.
src/docs                                 |  WARN  src\docs > @docusaurus/preset-classic > @docusaurus/theme-search-algolia > @docsearch/react: @algolia/autocomplete-preset-algolia@1.5.2 requires a peer of @algolia/client-search@^4.9.1 but none was installed.
src/docs                                 |  WARN  src\docs > @docusaurus/preset-classic > @docusaurus/theme-search-algolia: @docsearch/react@3.0.0 requires a peer of @types/react@>= 16.8.0 < 18.0.0 but none was installed.
src/docs                                 |  WARN  src\docs: mdx-mermaid@1.2.1 requires a peer of mermaid@>= 8.11.0 < 8.12.0 but version 8.14.0 was installed.
src/docs                                 |  WARN  src\docs: mdx-mermaid@1.2.1 requires a peer of unist-util-visit@^2.0.0 but none was installed.
src/web                                  |  WARN  src\web: babel-loader@8.2.3 requires a peer of webpack@>=2 but none was installed.
src/web                                  |  WARN  src\web: terser-webpack-plugin@5.3.1 requires a peer of webpack@^5.1.0 but none was installed.
src/web                                  |  WARN  src\web > next-pwa: clean-webpack-plugin@4.0.0 requires a peer of webpack@>=4.0.0 <6.0.0 but none was installed.
src/web                                  |  WARN  src\web > next-pwa: workbox-webpack-plugin@6.4.2 requires a peer of webpack@^4.4.0 || ^5.9.0 but none was installed.
 WARN  @typescript-eslint/eslint-plugin > @typescript-eslint/experimental-utils > @typescript-eslint/typescript-estree: tsutils@3.21.0 requires a peer of 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 but none was installed.
 WARN  @typescript-eslint/eslint-plugin > @typescript-eslint/experimental-utils: eslint-utils@3.0.0 requires a peer of eslint@>=5 but none was installed.
 WARN  @typescript-eslint/eslint-plugin: @typescript-eslint/experimental-utils@4.33.0 requires a peer of eslint@* but none was installed.
 WARN  @typescript-eslint/eslint-plugin@4.33.0 requires a peer of eslint@^5.0.0 || ^6.0.0 || ^7.0.0 but none was installed.
 WARN  @typescript-eslint/parser@4.33.0 requires a peer of eslint@^5.0.0 || ^6.0.0 || ^7.0.0 but none was installed.
 WARN  jest-playwright-preset@1.7.0 requires a peer of jest-circus@>=26.6.3 but none was installed.
 WARN  jest-playwright-preset@1.7.0 requires a peer of jest-environment-node@>=26.6.3 but none was installed.
 WARN  jest-playwright-preset@1.7.0 requires a peer of jest-runner@>=26.6.3 but none was installed.
 WARN  ts-jest@27.1.3 requires a peer of typescript@>=3.8 <5.0 but none was installed.
 WARN  ioredis-mock@5.9.1 requires a peer of redis-commands@1.x but none was installed.

I think you're getting peer-dependency deprecation warnings somehow

cindyorangis commented 2 years ago

We can set auto-install-peers=true in .npmrc to automatically install missing peer dependencies as dev dependencies

https://pnpm.io/npmrc#auto-install-peers

cindyorangis commented 2 years ago

Wow, this is the output I get for pnpm install on an AWS EC2 Amazon Linux 2 AMI

[ec2-user@ip-172-31-11-98 telescope]$ pnpm install
Scope: all 16 workspace projects
src/web                                  |  WARN  deprecated @material-ui/core@4.12.3
src/docs                                 |  WARN  deprecated @braintree/sanitize-url@3.1.0
src/api/posts                            |  WARN  deprecated superagent@6.1.0
src/docs                                 |  WARN  deprecated querystring@0.2.1
src/api/posts                            |  WARN  deprecated formidable@1.2.6
src/web                                  |  WARN  deprecated source-map-url@0.4.1
src/web                                  |  WARN  deprecated source-map-url@0.4.1
src/docs                                 |  WARN  deprecated querystring@0.2.0
tools/autodeployment                     |  WARN  deprecated uuid@3.4.0
tools/autodeployment                     |  WARN  deprecated uuid@3.4.0
 WARN  deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.
tools/autodeployment                     |  WARN  deprecated uuid@3.4.0
 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-runner@>=26.6.3                                         
  jest-circus@>=26.6.3                                         redis-commands@1.x                                           
  jest-environment-node@>=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    typescript@">= 2.7"              
  @types/react@">=16.8.0 <18.0.0"  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"