Open dingshaohua-com opened 1 year ago
打包时候也报错
> Task :react-native-track-player:compileReleaseJavaWithJavac
注: 某些输入文件使用或覆盖了已过时的 API。
注: 有关详细信息, 请使用 -Xlint:deprecation 重新编译。
注: 某些输入文件使用了未经检查或不安全的操作。
注: 有关详细信息, 请使用 -Xlint:unchecked 重新编译。
> Task :app:createBundleReleaseJsAndAssets
warn Package react-native-navigation contains invalid configuration: "dependency.assets" is not allowed,"dependency.hooks" is not allowed. Please verify it's properly linked using "react-native config" command and contact the package maintainers about this.
warning: the transform cache was reset.
Welcome to Metro v0.73.9
Fast - Scalable - Integrated
info Writing bundle output to:, android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle
info Writing sourcemap output to:, android\app\build\intermediates\sourcemaps\react\release\index.android.bundle.packager.map
info Done writing bundle output
info Done writing sourcemap output
info Copying 8 asset files
info Done copying assets
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:741:16: warning: the variable "SharedArrayBuffer" was not declared in function "from"
if (typeof SharedArrayBuffer !== 'undefined' && (isInstance(value, SharedArrayBuffer) || value && isInstance(value.buffer, SharedArrayBuffer))) {
^~~~~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:3310:23: warning: the variable "DebuggerInternal" was not declared in function "__shouldPauseOnThrow"
return typeof DebuggerInternal !== 'undefined' && DebuggerInternal.shouldPauseOnThrow === true;
^~~~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:6530:7: warning: the variable "setTimeout" was not declared in function "logCapturedError"
setTimeout(function () {
^~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:4504:108: warning: the variable "nativeFabricUIManager" was not declared in function "onChange"
(fromOrTo = fromOrTo && fromOrTo.stateNode) && fromOrTo.canonical._internalInstanceHandle ? (from && nativeFabricUIManager.setIsJSResponder(from.stateNode.node, false, blockNativeResponder || false), to && nativeFabricUIManager.setIsJSResponder(to.stateNode.node, true, blockNativeResponder || false)) : null !== to ? _$$_REQUIRE(_dependencyMap[2]).UIManager.setJSResponder(to.stateNode.canonical._nativeTag, blockNativeResponder) : _$$_REQUIRE(_dependencyMap[2]).UIManager.clearJSResponder();
^~~~~~~~~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:5111:21: warning: the variable "clearTimeout" was not declared in anonymous function " 119#"
cancelTimeout = clearTimeout;
^~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:8861:30: warning: the variable "__REACT_DEVTOOLS_GLOBAL_HOOK__" was not declared in anonymous function " 119#"
if ("undefined" !== typeof __REACT_DEVTOOLS_GLOBAL_HOOK__) {
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:9630:5: warning: the variable "setImmediate" was not declared in function "handleResolved"
setImmediate(function () {
^~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:9841:16: warning: the variable "AggregateError" was not declared in function "getAggregateError"
if (typeof AggregateError === 'function') {
^~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12498:12: warning: the variable "fetch" was not declared in anonymous function " 321#"
fetch: fetch,
^~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12499:14: warning: the variable "Headers" was not declared in anonymous function " 321#"
Headers: Headers,
^~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12500:14: warning: the variable "Request" was not declared in anonymous function " 321#"
Request: Request,
^~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12501:15: warning: the variable "Response" was not declared in anonymous function " 321#"
Response: Response
^~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12649:24: warning: the variable "FileReader" was not declared in function "readBlobAsArrayBuffer"
var reader = new FileReader();
^~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12686:36: warning: the variable "Blob" was not declared in anonymous function " 332#"
} else if (support.blob && Blob.prototype.isPrototypeOf(body)) {
^~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12688:40: warning: the variable "FormData" was not declared in anonymous function " 332#"
} else if (support.formData && FormData.prototype.isPrototypeOf(body)) {
^~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12690:44: warning: the variable "URLSearchParams" was not declared in anonymous function " 332#"
} else if (support.searchParams && URLSearchParams.prototype.isPrototypeOf(body)) {
^~~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12917:23: warning: the variable "XMLHttpRequest" was not declared in anonymous function " 341#"
var xhr = new XMLHttpRequest();
^~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:12510:76: warning: the variable "self" was not declared in anonymous function " 324#"
var global = typeof globalThis !== 'undefined' && globalThis || typeof self !== 'undefined' && self || typeof global !== 'undefined' && global;
^~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:18149:27: warning: the variable "performance" was not declared in anonymous function " 580#"
if ("object" === typeof performance && "function" === typeof performance.now) {
^~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:18172:26: warning: the variable "navigator" was not declared in anonymous function " 580#"
"undefined" !== typeof navigator && undefined !== navigator.scheduling && undefined !== navigator.scheduling.isInputPending && navigator.scheduling.isInputPending.bind(navigator.scheduling);
^~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:18239:37: warning: the variable "MessageChannel" was not declared in anonymous function " 580#"
};else if ("undefined" !== typeof MessageChannel) {
^~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:26438:34: warning: the variable "requestAnimationFrame" was not declared in function "start 9#"
this._animationFrame = requestAnimationFrame(this.onUpdate.bind(this));
^~~~~~~~~~~~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:49737:16: warning: the variable "TextEncoder" was not declared in anonymous function " 1714#"
if (typeof TextEncoder === 'function' && TextEncoder.prototype.encode) {
^~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:49800:16: warning: the variable "TextDecoder" was not declared in anonymous function " 1715#"
if (typeof TextDecoder === 'function' && TextDecoder.prototype.decode) {
^~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:58011:7: warning: the variable "add32" was not declared in anonymous function " 1955#"
add32 = function add32(x, y) {
^~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:59830:27: warning: the variable "external" was not declared in function "callCmd"
a = external.superCall(n.cmd, n.jsonStr);
^~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:66934:18: warning: the variable "setInterval" was not declared in anonymous function " 2421#"
var poll = setInterval(getProgress, updateInterval || 1000);
^~~~~~~~~~~
android\app\build\ASSETS\createBundleReleaseJsAndAssets\index.android.bundle:66936:16: warning: the variable "clearInterval" was not declared in anonymous function " 2422#"
return clearInterval(poll);
^~~~~~~~~~~~~
> Task :app:mergeReleaseResources FAILED
ERROR:[drawable-mdpi-v4/src_resources_images_defaultuser] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_resources_images_defaultuser.jpg [drawable-mdpi-v4/src_resources_images_defaultuser] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_resources_images_defaultuser.jpg: Resource and asset merger: Duplicate resources
ERROR:[drawable-mdpi-v4/src_resources_images_notificationxhdpi] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_resources_images_notificationxhdpi.png [drawable-mdpi-v4/src_resources_images_notificationxhdpi] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_resources_images_notificationxhdpi.png: Resource and asset merger: Duplicate resource
ERROR:[drawable-mdpi-v4/src_theme_themes_images_china_ink] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_china_ink.jpg [drawable-mdpi-v4/src_theme_themes_images_china_ink] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_china_ink.jpg: Resource and asset merger: Duplicate resources
ERROR:[drawable-mdpi-v4/src_theme_themes_images_jqbg] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_jqbg.jpg [drawable-mdpi-v4/src_theme_themes_images_jqbg] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_jqbg.jpg: Resource and asset merger: Duplicate resources
ERROR:[drawable-mdpi-v4/src_theme_themes_images_landingmoon2] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_landingmoon2.png [drawable-mdpi-v4/src_theme_themes_images_landingmoon2] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_landingmoon2.png: Resource and asset merger: Duplicate resources
ERROR:[drawable-mdpi-v4/src_theme_themes_images_myzcbg] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_myzcbg.jpg [drawable-mdpi-v4/src_theme_themes_images_myzcbg] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_myzcbg.jpg: Resource and asset merger: Duplicate resources
ERROR:[drawable-mdpi-v4/src_theme_themes_images_xnkl] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_xnkl.png [drawable-mdpi-v4/src_theme_themes_images_xnkl] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_xnkl.png: Resource and asset merger: Duplicate resources
ERROR:[raw/src_resources_medias_silence02s] D:\pub-code\lx-music-mobile\android\app\src\main\res\raw\src_resources_medias_silence02s.mp3 [raw/src_resources_medias_silence02s] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\raw\src_resources_medias_silence02s.mp3: Resource and asset merger: Duplicate resources
FAILURE: Build completed with 2 failures.
1: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:mergeReleaseResources'.
> [drawable-mdpi-v4/src_resources_images_defaultuser] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_resources_images_defaultuser.jpg [drawable-mdpi-v4/src_resources_images_defaultuser] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_resources_images_defaultuser.jpg: Error: Duplicate resources
[drawable-mdpi-v4/src_resources_images_notificationxhdpi] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_resources_images_notificationxhdpi.png [drawable-mdpi-v4/src_resources_images_notificationxhdpi] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_resources_images_notificationxhdpi.png: Error: Duplicate resources
[drawable-mdpi-v4/src_theme_themes_images_china_ink] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_china_ink.jpg [drawable-mdpi-v4/src_theme_themes_images_china_ink] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_china_ink.jpg: Error: Duplicate resources
[drawable-mdpi-v4/src_theme_themes_images_jqbg] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_jqbg.jpg [drawable-mdpi-v4/src_theme_themes_images_jqbg] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_jqbg.jpg: Error: Duplicate resources
[drawable-mdpi-v4/src_theme_themes_images_landingmoon2] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_landingmoon2.png [drawable-mdpi-v4/src_theme_themes_images_landingmoon2] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_landingmoon2.png: Error: Duplicate resources
[drawable-mdpi-v4/src_theme_themes_images_myzcbg] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_myzcbg.jpg [drawable-mdpi-v4/src_theme_themes_images_myzcbg] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_myzcbg.jpg: Error: Duplicate resources
[drawable-mdpi-v4/src_theme_themes_images_xnkl] D:\pub-code\lx-music-mobile\android\app\src\main\res\drawable-mdpi\src_theme_themes_images_xnkl.png [drawable-mdpi-v4/src_theme_themes_images_xnkl] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\drawable-mdpi\src_theme_themes_images_xnkl.png: Error: Duplicate resources
[raw/src_resources_medias_silence02s] D:\pub-code\lx-music-mobile\android\app\src\main\res\raw\src_resources_medias_silence02s.mp3 [raw/src_resources_medias_silence02s] D:\pub-code\lx-music-mobile\android\app\build\generated\res\react\release\raw\src_resources_medias_silence02s.mp3: Error: Duplicate resources
* 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.
==============================================================================
2: Task failed with an exception.
-----------
* What went wrong:
java.lang.StackOverflowError (no error message)
* 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 8.0.
You can use '--warning-mode all' to show the individual deprecation warnings and determine if they come from your own scripts or plugins.
See https://docs.gradle.org/7.5.1/userguide/command_line_interface.html#sec:command_line_warnings
BUILD FAILED in 2m 27s
334 actionable tasks: 325 executed, 9 up-to-date
* 终端进程“C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -Command npm run pack”已终止,退出代码: 1。
* 终端将被任务重用,按任意键关闭。
太困难了 一步一个坑,解决完一个 就会出现另一个
删除mode_modules后重新装依赖
解决方案检查
预期行为
npm run start
期望启动成功实际行为
Lx Music 版本
1.0.6
最后正常的版本
No response
操作系统版本
windows11
附加信息
No response