Skip to content

Running yarn app:android on Windows 11 failed. #8853

@lmxdawn

Description

@lmxdawn

** I want to participate in the development, but I'm getting an error when running it on Windows 11. Below is the log.**

> Task :app:createBundleProdDebugJsAndAssets
鈼? Validation Warning:

  Unknown option "fileMapCacheDirectory" with value "C:\\app-monorepo\\apps\\mobile\\node_modules\\.cache\\file-map-cache" was found.
  This is probably a typing mistake. Fixing it will remove this message.

Starting Metro Bundler
warning: Bundler cache is empty, rebuilding (this may take a minute)
Error: Unable to resolve module ./index.ts from C:\app-monorepo/.: 

None of these files exist:
  * ..\..\index.ts(.android.ts|.native.ts|.ts|.android.tsx|.native.tsx|.tsx|.android.mjs|.native.mjs|.mjs|.android.js|.native.js|.js|.android.jsx|.native.jsx|.jsx|.android.json|.native.json|.json|.android.cjs|.native.cjs|.cjs|.android.scss|.native.scss|.scss|.android.sass|.native.sass|.sass|.android.css|.native.css|.css|.android.text-js|.native.text-js|.text-js|.android.d.ts|.native.d.ts|.d.ts|.android.cjs|.native.cjs|.cjs|.android.min.js|.native.min.js|.min.js)
  * ..\..\index.ts
Error: Unable to resolve module ./index.ts from C:\app-monorepo/.: 

None of these files exist:
  * ..\..\index.ts(.android.ts|.native.ts|.ts|.android.tsx|.native.tsx|.tsx|.android.mjs|.native.mjs|.mjs|.android.js|.native.js|.js|.android.jsx|.native.jsx|.jsx|.android.json|.native.json|.json|.android.cjs|.native.cjs|.cjs|.android.scss|.native.scss|.scss|.android.sass|.native.sass|.sass|.android.css|.native.css|.css|.android.text-js|.native.text-js|.text-js|.android.d.ts|.native.d.ts|.d.ts|.android.cjs|.native.cjs|.cjs|.android.min.js|.native.min.js|.min.js)
  * ..\..\index.ts
    at ModuleResolver.resolveDependency (C:\app-monorepo\node_modules\metro\src\node-haste\DependencyGraph\ModuleResolution.js:114:15)
    at DependencyGraph.resolveDependency (C:\app-monorepo\node_modules\metro\src\node-haste\DependencyGraph.js:239:43)
    at C:\app-monorepo\node_modules\metro\src\lib\transformHelpers.js:165:21
    at Server._resolveRelativePath (C:\app-monorepo\node_modules\metro\src\Server.js:1120:12)
    at MetroBundlerDevServer.resolveRelativePathAsync (C:\app-monorepo\node_modules\@expo\cli\src\start\server\metro\MetroBundlerDevServer.ts:1781:12)
    at MetroBundlerDevServer.metroLoadModuleContents (C:\app-monorepo\node_modules\@expo\cli\src\start\server\metro\MetroBundlerDevServer.ts:540:35)
    at MetroBundlerDevServer.legacySinglePageExportBundleAsync (C:\app-monorepo\node_modules\@expo\cli\src\start\server\metro\MetroBundlerDevServer.ts:867:20)
    at exportEmbedBundleAndAssetsAsync (C:\app-monorepo\node_modules\@expo\cli\src\export\embed\exportEmbedAsync.ts:206:21)
    at exportEmbedInternalAsync (C:\app-monorepo\node_modules\@expo\cli\src\export\embed\exportEmbedAsync.ts:137:37)
    at exportEmbedAsync (C:\app-monorepo\node_modules\@expo\cli\src\export\embed\exportEmbedAsync.ts:117:3)

> Task :app:createBundleProdDebugJsAndAssets FAILED

[Incubating] Problems report is available at: file:///C:/app-monorepo/apps/mobile/android/build/reports/problems/problems-report.html

FAILURE: Build failed with an exception.                                                                                                                                                                                                                                          

* What went wrong:
Execution failed for task ':app:createBundleProdDebugJsAndAssets'.
> Process 'command 'cmd'' finished with non-zero exit value 1

* Try:
> Run with --stacktrace option to get the stack trace.
> Run with --info or --debug option to get more log output.
> Run with --scan to get full insights.
> Get more help at https://help.gradle.org.

Deprecated Gradle features were used in this build, making it incompatible with Gradle 9.0.

You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.

For more on this, please refer to https://docs.gradle.org/8.13/userguide/command_line_interface.html#sec:command_line_warnings in the Gradle documentation.

BUILD FAILED in 10s
145 actionable tasks: 6 executed, 139 up-to-date
Error: C:\app-monorepo\apps\mobile\android\gradlew.bat app:assembleProdDebug -x lint -x test --configure-on-demand --build-cache -PreactNativeDevServerPort=8081 -PreactNativeArchitectures=x86_64,arm64-v8a exited with non-zero code: 1
Error: C:\app-monorepo\apps\mobile\android\gradlew.bat app:assembleProdDebug -x lint -x test --configure-on-demand --build-cache -PreactNativeDevServerPort=8081 -PreactNativeArchitectures=x86_64,arm64-v8a exited with non-zero code: 1
    at ChildProcess.completionListener (C:\app-monorepo\node_modules\@expo\spawn-async\src\spawnAsync.ts:67:13)
    at Object.onceWrapper (node:events:634:26)
    at ChildProcess.emit (node:events:519:28)
    at ChildProcess.cp.emit (C:\app-monorepo\node_modules\cross-spawn\lib\enoent.js:34:29)
    at maybeClose (node:internal/child_process:1101:16)
    at Process.ChildProcess._handle.onexit (node:internal/child_process:304:5)
    ...
    at spawnAsync (C:\app-monorepo\node_modules\@expo\spawn-async\src\spawnAsync.ts:28:21)
    at spawnGradleAsync (C:\app-monorepo\node_modules\@expo\cli\src\start\platforms\android\gradle.ts:134:28)
    at assembleAsync (C:\app-monorepo\node_modules\@expo\cli\src\start\platforms\android\gradle.ts:83:16)
    at runAndroidAsync (C:\app-monorepo\node_modules\@expo\cli\src\run\android\runAndroidAsync.ts:62:24)

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions