wechat-miniprogram / wechat-miniprogram/miniprogram-demo

npm run init 就报错

Open
#60 7 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
7.2k
Forks
2.2k
Avg merge
10h 34m
Merged PRs (30d)
2

Description

第一次报错是找不到 tnpm。改成 npm 后其他报错如下。

`PS D:\WeChat\miniprogram-demo> npm run init

miniprogram-demo@1.0.0 init
cd cloudfunctions/ && tnpm i --production && cd ../miniprogram/ && tnpm i --production

'tnpm' 不是内部或外部命令,也不是可运行的程序
或批处理文件。
PS D:\WeChat\miniprogram-demo> npm run init

miniprogram-demo@1.0.0 init
cd cloudfunctions/ && npm i --production && cd ../miniprogram/ && npm i --production

npm WARN config production Use --omit=dev instead.
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: miniprogram-demo@1.0.0
npm ERR! Found: eslint@7.32.0
npm ERR! node_modules/eslint
npm ERR! dev eslint@"^7.1.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer eslint@"^4.19.1 || ^5.3.0" from eslint-config-airbnb-base@13.1.0
npm ERR! node_modules/eslint-config-airbnb-base
npm ERR! dev eslint-config-airbnb-base@"13.1.0" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See C:\Users\chao\AppData\Local\npm-cache\eresolve-report.txt for a full report.

npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\chao\AppData\Local\npm-cache_logs\2022-08-22T03_20_33_300Z-debug-0.log`

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by running npm run init and inspect the command that installs dependencies in cloudfunctions/ and miniprogram/. Check the reported npm dependency conflict between eslint@7.32.0 and eslint-config-airbnb-base@13.1.0, then verify that initialization completes successfully with the documented package manager.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.