You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 7, 2023. It is now read-only.
I enclosed the complete output when running turtle, including the stack trace and command used.
Issue Description
Building a standalone Android app fails due to an incompatibility with modern versions of Yarn (berry, or more specifically in this case, Yarn 3). On line 106 of src/bin/setup/android/index.ts the yarn/npm command is invoked with the following flags: 'install', '--ignore-scripts', '--production'. However, in Yarn 3, these are not valid flags and using them results in a failure to build the app.
Valid flags for yarn install in Yarn v3 are: --json, --immutable, --immutable-cache, --check-cache, --inline-builds, --mode #0
I'm not certain what the flags should be in order to replicate the yarn v1 behavior. The official Yarn docs on this page (towards the bottom of the page) describe how to achieve the same affect as yarn install --production but its using the workspaces focus command to do so instead of the install command. I'm unsure if that would work as a drop in replacement because I haven't used that particular feature in Yarn 3.
Ideally, using any version of Yarn would result in a successful build.
This problem did not happen when building a standalone iOS app.
Complete output when running turtle, including the stack trace and command used
Dec 22 19:38:23 turtle[6381] INFO: extracting shell app (this may take a while)...
platform: "android"
buildPhase: "setting up environment"
Dec 22 19:40:12 turtle[6381] INFO: shell app extracted
platform: "android"
buildPhase: "setting up environment"
Dec 22 19:40:12 turtle[6381] INFO: installing dependencies in /Users/vagrant/.turtle/workingdir/android/sdk41 directory...
platform: "android"
buildPhase: "setting up environment"
Dec 22 19:40:12 turtle[6381] INFO: Unknown Syntax Error: Unsupported option name ("--ignore-scripts").
platform: "android"
buildPhase: "setting up environment"
source: "stdout"
Dec 22 19:40:12 turtle[6381] INFO: $ yarn install [--json] [--immutable] [--immutable-cache] [--check-cache] [--inline-builds] [--mode #0]
platform: "android"
buildPhase: "setting up environment"
source: "stdout"
Dec 22 19:40:12 turtle[6381] ERROR: Failed to build standalone app
err: Error: yarn exited with non-zero code: 1
at ChildProcess.completionListener (/Users/vagrant/git/node_modules/@expo/spawn-async/src/spawnAsync.ts:65:13)
at Object.onceWrapper (events.js:421:26)
at ChildProcess.emit (events.js:314:20)
at ChildProcess.EventEmitter.emit (domain.js:483:12)
at maybeClose (internal/child_process.js:1022:16)
at Socket. (internal/child_process.js:444:11)
at Socket.emit (events.js:314:20)
at Socket.EventEmitter.emit (domain.js:483:12)
at Pipe. (net.js:675:12)
...
at spawnAsync (/Users/vagrant/git/node_modules/@expo/spawn-async/src/spawnAsync.ts:26:19)
at Object.spawnAsyncThrowError (/@expo/[email protected]/src/detach/ExponentTools.ts:111:19)
at _installNodeModules (/Users/vagrant/git/node_modules/turtle-cli/src/bin/setup/android/index.ts:106:23)
at _shellAppPostDownloadAction (/Users/vagrant/git/node_modules/turtle-cli/src/bin/setup/android/index.ts:91:5)
at Object.ensureShellAppIsPresent (/Users/vagrant/git/node_modules/turtle-cli/src/bin/setup/utils/common.ts:40:5)
at Object.setup [as default] (/Users/vagrant/git/node_modules/turtle-cli/src/bin/setup/android/index.ts:60:5)
at Object.setup [as default] (/Users/vagrant/git/node_modules/turtle-cli/src/bin/setup/setup.ts:15:12)
at /Users/vagrant/git/node_modules/turtle-cli/src/bin/utils/builder.ts:79:7
at Command. (/Users/vagrant/git/node_modules/turtle-cli/src/bin/index.ts:23:12)
platform: "android"
New Issue Checklist
yarn global add turtle-cli
ornpm install --global turtle-cli
).Issue Description
Building a standalone Android app fails due to an incompatibility with modern versions of Yarn (berry, or more specifically in this case, Yarn 3). On line 106 of
src/bin/setup/android/index.ts
the yarn/npm command is invoked with the following flags: 'install', '--ignore-scripts', '--production'. However, in Yarn 3, these are not valid flags and using them results in a failure to build the app.Valid flags for
yarn install
in Yarn v3 are: --json, --immutable, --immutable-cache, --check-cache, --inline-builds, --mode #0I'm not certain what the flags should be in order to replicate the yarn v1 behavior. The official Yarn docs on this page (towards the bottom of the page) describe how to achieve the same affect as
yarn install --production
but its using theworkspaces focus
command to do so instead of theinstall
command. I'm unsure if that would work as a drop in replacement because I haven't used that particular feature in Yarn 3.Ideally, using any version of Yarn would result in a successful build.
This problem did not happen when building a standalone iOS app.
Command executed
Complete output when running turtle, including the stack trace and command used
Environment
The text was updated successfully, but these errors were encountered: