NativeScript / NativeScript/plugins

demo not working : Cannot find module 'plugins/dist/packages/detox/postinstall.js'

未关闭
#543 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

主要语言
TypeScript
星标
206
派生
123
平均合并
2 天 1 小时
30 天内合并 PR
1

描述

Hi,

Angular demo apps is not working.

Here the steps i follow :

git clone git@github.com:NativeScript/plugins.git
cd plugins
npm run setup
npm start

within npm start :

  • @nativescript.build-all
  • apps.demo-angular.ios

The log :

Running NativeScript CLI within apps/demo-angular
 
ns debug ios --no-hmr --force
 
---
Searching for devices...
Unable to install dependencies. Make sure your package.json is valid and all dependencies are correct. Error is: Command npm failed with exit code 1 Error output: 
 npm ERR! code 1
npm ERR! path /Users/alexist/plugins/dist/packages/detox
npm ERR! command failed
npm ERR! command sh -c -- node postinstall.js
npm ERR! node:internal/modules/cjs/loader:1080
npm ERR!   throw err;
npm ERR!   ^
npm ERR! 
npm ERR! Error: Cannot find module '/Users/alexist/plugins/dist/packages/detox/postinstall.js'
npm ERR!     at Module._resolveFilename (node:internal/modules/cjs/loader:1077:15)
npm ERR!     at Module._load (node:internal/modules/cjs/loader:922:27)
npm ERR!     at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12)
npm ERR!     at node:internal/main/run_main_module:23:47 {
npm ERR!   code: 'MODULE_NOT_FOUND',
npm ERR!   requireStack: []
npm ERR! }
npm ERR! 
npm ERR! Node.js v18.16.1

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/alexist/.npm/_logs/2023-11-07T16_50_18_973Z-debug-0.log

Done.

 

 >  NX   Running target ios for project demo-angular and 71 tasks it depends on failed

My environment :

  • os : macos
  • yarn : 1.22.19
  • node : v18.16.1
  • npm : 8.19.4

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

先从 npm run setup 和 npm start 入口开始,然后检查 apps.demo-angular.ios 的构建,以及错误中提到的生成路径 dist/packages/detox。确认 postinstall.js 缺失的原因,并验证 Angular iOS demo 能够在没有 MODULE_NOT_FOUND 错误的情况下成功运行。

由索引模型根据 Issue 内容生成。

评估

技术栈
ios, node.js
领域
build-system, mobile
Issue 类型
缺陷
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
需要澄清
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。