yinxin630 / fiora

An interesting open source chat application. Developed with node.js, mongoDB, socket.io and react
https://fiora.suisuijiang.com
MIT License
6.57k stars 1.31k forks source link

app构建失败 #516

Closed Adsicmes closed 1 year ago

Adsicmes commented 2 years ago

(base) frz@VM-4-5-debian:~/fiora_web_chat/fiora$ sudo expo build:android -t apk

expo build:android has been superseded by eas build. Learn more: https://blog.expo.dev/turtle-goes-out-to-sea-d334db2a6b60

Run the following:

› npm install -g eas-cli
› eas build -p android https://docs.expo.dev/build/setup/

expo build:android will be discontinued on January 4, 2023 (119 days left).

Checking if there is a build in progress...

Accessing credentials for adsicmes in project fiora
✔ Would you like to upload a Keystore or have us generate one for you?
If you don't know what this means, let us generate it! :) › Generate new keystore
The `keytool` utility was not found in your PATH. A new Keystore will be generated on Expo servers.

› Expo SDK: 46.0.0
› Release channel: default
› Workflow: Managed

- Optimization: Project may contain uncompressed images. Optimizing image assets can improve app size and performance.
  To fix this, run npx expo-optimize. Learn more: https://docs.expo.dev/distribution/optimizing-updates/#optimize-images

Building optimized bundles and generating sourcemaps...
Warning: Invalid version react-native@0.70.0 for expo sdkVersion 46.0.0. Use react-native@0.69.5
Starting Metro Bundler
Started Metro Bundler
Unable to resolve module child_process from /home/frz/fiora_web_chat/fiora/index.ts: child_process could not be found within the project or in these directories:
  node_modules
  2 |
  3 | import { program } from 'commander';
> 4 | import cp from 'child_process';
    |                 ^
  5 | import i18n from './packages/i18n/node.index';
  6 |
  7 | function exec(commandStr: string) {
Error: Unable to resolve module child_process from /home/frz/fiora_web_chat/fiora/index.ts: child_process could not be found within the project or in these directories:
  node_modules
  2 |
  3 | import { program } from 'commander';
> 4 | import cp from 'child_process';
    |                 ^
  5 | import i18n from './packages/i18n/node.index';
  6 |
  7 | function exec(commandStr: string) {
    at ModuleResolver.resolveDependency (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:178:15)
    at DependencyGraph.resolveDependency (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/node-haste/DependencyGraph.js:264:43)
    at Object.resolve (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/lib/transformHelpers.js:170:21)
    at resolveDependencies (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/DeltaBundler/graphOperations.js:467:33)
    at processModule (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/DeltaBundler/graphOperations.js:232:31)
    at traverseDependenciesForSingleFile (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/DeltaBundler/graphOperations.js:221:3)
    at async Promise.all (index 0)
    at initialTraverseDependencies (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/DeltaBundler/graphOperations.js:204:3)
    at DeltaCalculator._getChangedDependencies (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/DeltaBundler/DeltaCalculator.js:208:25)
    at DeltaCalculator.getDelta (/home/frz/fiora_web_chat/fiora/node_modules/metro/src/DeltaBundler/DeltaCalculator.js:90:16)

(base) frz@VM-4-5-debian:~/fiora_web_chat/fiora$ 
ouyangyanhuo commented 1 year ago

我使用的命令是 'npm install -g eas-cli' ‘eas login’ ‘eas build:configure ‘eas build --platform android’ 就可以在 Expo 上看到开始构建了,应该是不能使用 ‘eas build -p android https://docs.expo.dev/build/setup/’ 的,因为这个SDK已经在23年1月停止支持了