I am trying to integrate the gradle plugin https://github.com/Triple-T/gradle-play-publisher in version 2.0.0-beta1 to automatically upload a new version of an APK to the PlayStore.
I followed the instructions and created a service account and linked it to my PlayStore account.
Then I added my key document (JSON) in the app/build.gradle.
If I call ./gradlew tasks in my Android project, I now also see the task 'bootstrap', publishApk,... but when I call e.g. bootstrap or publishApk nothing happens.
No Taks does anythink right now :(
When I call ./gradlew -i bootstrap it says:
Task :app:bootstrap UP-TO-DATE Skipping task ':app:bootstrap' as it
has no actions.
Does anyone have any idea where my mistake is?
FYI:
I'm trying to do this in Android Studio 3.2.
Oh damn....
after reading the bug https://github.com/Triple-T/gradle-play-publisher/issues/81 and the corresponding answers until the end i noticed that my release-build has set the property debuggable true at the moment (due to tests). After removing this the plugin works as expected.
Sorry for the confusion ;)
Related
(using android,
openjdk-11.0.13_8
node v16.13.2
react-native 0.67.0)
i created a barebone react-native project with
npx react-native init testapp
then signed it according to official react-native documentation
then tried to create the release-variant with npx react-native run-android --variant=release
now i get BUILD SUCCESSFUL message and got apk, and it installs and works in my physical device...
BUT, i got a lot of gradle problem-warning ...here is one sample..
Task :app:processReleaseManifestForPackage Execution optimizations have been disabled for task ':app:processReleaseManifestForPackage' to
ensure correctness due to the following reasons:
Gradle detected a problem with the following location: 'D:\testapp\android\app\build\intermediates\merged_manifests\release'.
Reason: Task ':app:processReleaseManifestForPackage' uses this output
of task ':app:copyReleaseBundledJs' without declaring an explicit or
implicit dependency. This can lead to incorrect results being
produced, depending on what order the tasks are executed. Please refer
to
https://docs.gradle.org/7.2/userguide/validation_problems.html#implicit_dependency
for more details about this problem.
this same problem-warning is repeated for many other tasks!!...
NB i havent added any packages or changed any source code.. its the barebone app coming with react-native!... so how do i solve this issue?.. how to fix my settings so that this warning can be removed...
(i copied one of these tasks-names and did a text-search inside all files in my project directory to find out where its mentioned...but shockingly, its not mentioned anywhere!!!...so where are all these problem-warnings coming from? and how can we get a neat gradle build?)
this same warning is repeated in lots of lines in gradle output for other tasks too, such as:
Task :app:compressReleaseAssets
Task :app:processReleaseManifestForPackage
etc.. etc..
My setup:
Android Gradle Plugin 3.5.0
Gradle to 5.5.1
100+ Gradle modules
lot of generated code (mostly Dagger + data binding)
When I checkout a branch which causes changes in generated code then usually I have to wipe out whole .gradle/caches directory to make the build succeed. Otherwise gradle build system tries to resolve some old generated code.
clean and cleanBuildCache don't help. Also a side note: so far I've been a happy user but since we updated tools to these versions then build caching stopped working properly. Any tips?
EDIT: Please note that not every change in generated code breaks the cache. It's nondeterministic for me so far.
Disclaimer: I'm a java developer and am not familiar with the Android plugin
The clean task won't remove entries from the build cache. The cache key is derived from the task inputs and outputs. If you haven't declared all of the task inputs correctly then the cache key won't be correct
If (for example) your "generate" task needs a template, some xml and a system property to generate the sources you will need to declare all three (template, xml and syspop) as task inputs to the "generate" task. Any output directory(s) will obviously need to be declared as a task output.
The last thing to consider is that the "generate" task is correctly wired into Gradle's DAG. Eg the "compileJava" task should "dependsOn" your "generate" task (or whatever the android equivalent task is)
Hey so I have recently started developing an app using flutter and I have already coma across a few issues. I'll quickly resume my situation :
My app uses firebase auth and I uses the android studio refactor feature for androidX.
This managed to get me a working application with a login form but no way to fill in the login form because the android API 28 has a bug in that it does not show the keyboard after you higlight the textinput. But for fire auth you need the API level 28 ...
I managed to get around this by using the flutter channel dev.
Now so far everything works login in and registering users with the firebase auth.
Next I want to implement the facebook login and this is where I encountered even more trouble.
I used the https://github.com/roughike/flutter_facebook_login package and followed all the steps and went through the whole configuration on the firebase page and the facebook developer page.
Add the res/strings.xml
Add permission the manifest
Add and the two under the application key in the android manifest
Add "implementation 'com.facebook.android:facebook-login:4.40.0'" under the app level gradle dependencies
Checked the jcenter() in the project level grable repositories
The actual dart code seems fine and the project builds and runs correctly on IOS
I do not get any errors even running flutter in verbose mode. The logcat is also completly empty.
I am at a complete loss it's really starting to feel like flutter is not really stable after all.
Any help would be greatly appreciated.
Thanks
EDIT: This issue seems to be androidX related and should be fixed as soon as this pull request :
https://github.com/roughike/flutter_facebook_login/pull/87/commits/70dec4403710eb4c52a98e035a0a5e7d7f551d76
is merged.
Ok I got it working by copying the repository locally and adding the changes in the aforementioned pull request.
Then in my pubspec file I used the path: key to set the dependency to my local file instead of the official git.
you can also use
git:
url: (url to your fork with the fixes in place)
I had to run flutter clean before rebuilding the app and now everything works.
EDIT A comment has just been added on the pull request thread :
As we are not sure when this will be merged, you can adjust your pubspec.yaml in the meantime:
dependency_overrides:
flutter_facebook_login:
git:
url: https://github.com/yudaprama/flutter_facebook_login
ref: android-x
When I build an apk with JavaFXPorts using gradle android, I find the apk under build\javafxports\android\MyApplication.apk. However, when I run any other gradle task after that, the apk is automatically and instantly getting DELETED.
I am clueless as to why this happens, since I'm not issuing a clean or anything like that.
Every time you run a task from the jfxmobile plugin, the Android, iOS and embedded extensions are added.
According to this, the folders javafxports/android and javafxports/tmp/android are deleted and created all over again. That means that any content there (your apk) will be removed.
If you think this is a bug, you can file an issue here.
You can also try to fix it, for instance by adding a task to do a backup of your apk every time you create it.
Something like this, added to the build.gradle file of your project, should work:
[android, androidInstall].each {task -> task.doLast() {
copy {
from 'build/javafxports/android'
into "build/apk"
}
}
}
I'd like to contribute to the F-Droid GitLab Repo.
I followed this guide: https://gitlab.com/fdroid/fdroiddata/blob/master/CONTRIBUTING.md
I have done this already, many times with a normal native app. That worked great. But with an Ionic app it seems to be different. I see, for example, no gradle data in my Ionic app. Do I need gradle? Because the build failed because he can not run gradle clean ..
Heres my stack:
==== detail begin ==== FAILURE: Build failed with an exception.
What went wrong: Task 'clean' not found in root project.
This is how my metadata file looks like:
Categories:System
License:GPL-3.0
[...]
Repo Type:git
Repo:<Repo Link>
Build:1.0,1
commit=<commit>
gradle=yes
Auto Update Mode:None
Update Check Mode:None
Everything in <> is filled out correctly.
You are forging new ground here! We (F-Droid) don't have solid support for Cordoba/Ionic/etc. but the only thing preventing it is someone doing the work! We're working on adding a new build field sudo= which will let you download and install whatever you need to run your build. I've never used Ionic, Cordoba, or any of these Javascript app things, so I don't know the details.
You can follow the progress of sudo= here:
https://gitlab.com/fdroid/fdroidserver/merge_requests/297
It'll still be a while yet before this is deployed on our infrastructure, but your testing it will speed up that process!