abhilashhm commented on issue #1585: URL: https://github.com/apache/cordova-android/issues/1585#issuecomment-1495711337
Thanks a lot for your response. Appreciate your time. It started working randomly. I tried adding the block you provided to the config.xml file: ``` <?xml version='1.0' encoding='utf-8'?> <widget id="com.abhi.camlin" version="1.0.0" xmlns="http://www.w3.org/ns/widgets" xmlns:cdv="http://cordova.apache.org/ns/1.0"> <name>Camlin School</name> <description>Camlin School App</description> <author email="[email protected]" href="#"> Abhilash H M </author> <content src="index.html" /> <allow-intent href="http://*/*" /> <allow-intent href="https://*/*" /> <icon src="www/images/school_logo.jpeg" /> <access origin="*" /> <allow-navigation href="*" /> <allow-navigation href="http://*/*" /> <allow-navigation href="https://*/*" /> <allow-navigation href="data:*" /> <preference name="AndroidInsecureFileModeEnabled" value="true" /> <preference name="scheme" value="https" /> <preference name="hostname" value="localhost" /> <platform name="android"> <edit-config file="app/src/main/AndroidManifest.xml" mode="merge" target="/manifest/application"> <application android:usesCleartextTraffic="true" /> </edit-config> </platform> </widget> ``` But during Cordova build android, it fails. ``` > Task :app:mergeDebugResources FAILED FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':app:mergeDebugResources'. > A failure occurred while executing com.android.build.gradle.internal.res.ResourceCompilerRunnable > Resource compilation failed (Failed to compile resource file: C:\Users\haniyura\SchoolAppCamlin\platforms\android\app\src\main\res\xml\config.xml: . Cause: com.ctc.wstx.exc.WstxParsingException: Undeclared namespace prefix "android" (for attribute "usesCleartextTraffic") at [row,col {unknown-source}]: [18,59]). Check logs for more details. * 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.4.2/userguide/command_line_interface.html#sec:command_line_warnings BUILD FAILED in 8s 43 actionable tasks: 3 executed, 40 up-to-date Command failed with exit code 1: C:\Users\haniyura\SchoolAppCamlin\platforms\android\gradlew cdvBuildDebug -b C:\Users\haniyura\SchoolAppCamlin\platforms\android\build.gradle ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
