ionic打包報錯-Error: java.util.concurrent.ExecutionException

版本參數(shù):

  • ionic : 3.19.1
  • cordova : 8.0.0
  • node : 8.7.0
  • npm : 5.4.2

**完整的報錯信息

Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
:mergeDebugResources FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':mergeDebugResources'.
> Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
Total time: 2.357 secs
Error: cmd: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':mergeDebugResources'.
> Error: java.util.concurrent.ExecutionException: com.android.ide.common.process.ProcessException:
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
[ERROR] An error occurred while running cordova run android (exit code 1).

**解決辦法


image.png

紅色區(qū)域的這張圖片進(jìn)行相同大小圖片的替換(不能刪除,只能替換),再次打包就能成功,以前在手機(jī)上面打包沒有出現(xiàn)出現(xiàn)過類似的問題,但最近升級了版本之后,手機(jī)卻不能正常打包了,網(wǎng)上查找了很多文章,無賴國內(nèi)資料有限,于是Google一番,雖然解決辦法找到了,卻因為英語能力有限,不能一一把問題的產(chǎn)生解釋出來,下面就是國外小哥提供的方法。

?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請聯(lián)系作者
【社區(qū)內(nèi)容提示】社區(qū)部分內(nèi)容疑似由AI輔助生成,瀏覽時請結(jié)合常識與多方信息審慎甄別。
平臺聲明:文章內(nèi)容(如有圖片或視頻亦包括在內(nèi))由作者上傳并發(fā)布,文章內(nèi)容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務(wù)。

相關(guān)閱讀更多精彩內(nèi)容

友情鏈接更多精彩內(nèi)容