My Android Studio was working fine couple of days ago.
But now whenever I create a new project in android studio it says Build: build failed with Input length = 1.
And under Run tasks, there's an error with :app:processDebugRecources
In the build.properties just add this line:
org.gradle.jvmargs='-Dfile.encoding=UTF-8'
Related
I just finisshed creating my capacitor app which I am trying to build in android studio but every time I run this command npx cap open android and android studio opened I am faced with
Gradle sync failed: Illegal char <:> at index 53:
C:/incidentApp/android/capacitor-cordova-android-plugins/C:-incidentApp-android-capacitor-cordova-android-plugins.iml
(1 m 28 s 869 ms)
Could someone please tell me what this error means and how I can solve it?
Try to locate the written file inside c:/incidentApp/android/capacitor-cordova-android-plugins/. It seems that there is an invalid character : in the file at the position resp. character 53. Remove the illegal character in the file. It may also help if you clean your project, and then build and sync again.
I'm trying to run a nativescript app on android using tns run android
I'm always getting gradle error:
FAILURE: Build failed with an exception.
* Where:
Build file:
'/Volumes/My_SSD/myproject/platforms/tempPlugin/kinvey_nativescript_sdk/bui
ld.gradle' line: 28
* What went wrong:
A problem occurred evaluating root project '`kinvey_nativescript_sdk`'.
> Failed to apply plugin [class 'org.gradle.api.plugins.BasePlugin']
> Could not create service of type OutputFilesRepository using ExecutionServices.createOutputFilesRepository().`
I tried the following:
Run ./gradlew --stacktrace but I got this error:
Caused by: org.gradle.cache.LockTimeoutException: Timeout waiting to lock
execution history cache
(/Volumes/My_SSD/myproject/platforms/tempPlugin/kinvey_nativescript_sdk/.gr
adle/5.1.1/executionHistory). It is currently in use by another Gradle
instance.
Owner PID: unknown
Our PID: 50331
Owner Operation: unknown
Our operation:
Lock file:
/Volumes/My_SSD/myproject/platforms/tempPlugin/kinvey_nativescript_sdk/.gra
dle/5.1.1/executionHistory/executionHistory.lock
Deleted .lock files manually and re-ran tns run android but I got the same error again
Run
chmod R+x/Volumes/My_SSD/myproject/platforms/tempPlugin/kinvey_nativescript_sdk
Didn't fix the problem
The app runs fine on ios emulator and but not on android
I was having the same problem, looks to be related with this Gradle issue.
The workaround I found here is to move the project to the home folder (~).
I am trying to add a new Run Configuration to an existing Android Project (Run -> Edit Configurations ...). When I click on Android Application in the Template section the dialog does not change:
I also get an IDE Fatal error with the following stack trace (only the beginning):
java.lang.NoClassDefFoundError: com/android/tools/idea/run/activity/StartActivityFlagsProvider
at com.android.tools.idea.run.AndroidRunConfigurationType$AndroidRunConfigurationFactory.createTemplateConfiguration(AndroidRunConfigurationType.java:45)
at com.intellij.execution.configurations.ConfigurationFactory.createTemplateConfiguration(ConfigurationFactory.java:64)
at com.intellij.execution.impl.RunManagerImpl.createTemplateSettings$intellij_platform_lang_impl(RunManagerImpl.kt:260)
at com.intellij.execution.impl.RunManagerImpl.getConfigurationTemplate(RunManagerImpl.kt:252)
at com.intellij.execution.impl.RunConfigurable.showTemplateConfigurable(RunConfigurable.kt:322)
Update 24.03.2019:
This problem also appears when I am creating a new project from a template.
When I load a project the event log looks like the following:
10:21 Gradle sync started
10:21 Project setup started
10:21 Gradle sync finished in 2 s 333 ms (from cached state)
10:21 Gradle sync failed: setup project failed: com/android/tools/idea/run/activity/StartActivityFlagsProvider (2 s 561 ms)
So I'm using GameMaker Studio Pro: 1.4.1657. I've installed all necessary SDKs, NDKs and other permissions. However, I cannot create and executable(.apk) for android.
Here is what the console says:
BUILD FAILED
C:\Android\tools\ant\build.xml:649: The following error occurred while executing this line:
C:\Android\tools\ant\build.xml:694: null returned: 1
Total time: 15 seconds
I've tried this solution: link Which didn't work.
Thanks! I would've posted this in the yoyogames forums, but I can't post! Thanks very much!
I am trying to integrate facebook using Plugin-x in cocos2d-x v3.5. I followed the following steps:
cd to MyProject/cocos2d/plugin/tools/
./publish.sh - on cygwin all the plugins get published one by one, for eg consider this Flurry trace
atarget dir is /Users/Shivam/Documents/Gautam/FinalWorkingApp/cocos2d/plugin/publish/plugins/flurry
android project dir is /Users/Shivam/Documents/Gautam/FinalWorkingApp/cocos2d/plugin/plugins/flurry/proj.android
Publish plugin for android
~/Documents/Gautam/FinalWorkingApp/cocos2d/plugin/plugins/flurry/proj.android ~/Documents/Gautam/FinalWorkingApp/cocos2d/plugin/tools ~/Documents/Gautam/FinalWorkingApp/cocos2d/plugin/tools
BUILD SUCCESSFUL
Total time: 0 seconds
BUILD FAILED
/Users/Shivam/Documents/Gautam/android-sdk-macosx/tools/ant/build.xml:542: Unable to resolve project target 'android-7'
Total time: 0 seconds
cp: /Users/Shivam/Documents/Gautam/FinalWorkingApp/cocos2d/plugin/plugins/flurry/proj.android/bin/*.jar: No such file or directory
~/Documents/Gautam/FinalWorkingApp/cocos2d/plugin/tools
~/Documents/Gautam/FinalWorkingApp/cocos2d/plugin/tools
All the plugins get published in the similar manner. I don't have android API 7, because of which it is failing, so can this be the reason my libpluginProtocol.jar is not getting generated?
I see a proper structure under under MyProject/cocos2d/plugin/publish/plugins
I also used gameDevGuide.sh and selected facebook.
Still I don't see libPluginProtocol.jar and libPluginFacebook.jar.
Please help. TIA
Ok so I found the answer. the library gets generated only when you have all the Android APIs viz, 7,8,10,17 and 19 apart from your own target APIs