Android Applink url resolving conflicts error - android

I added .well-known/assetlinks.json to my site and when I try link and verify in android studio app link assistant it says "Success! Your app is associated with the selected domains." But when I test app links in android studio it says "URL resolving conflicts please link and verify your digital asset links". But in link and verify tab it says ok!
My application id is correct and I am trying on test apk on my mac and sha fingerprints is also correct.
what am i missing?

I get this error if the adb use libusb backend checkbox is not checked.
Go to Android Studio > User > Preferences... and on the left side menu click Build, Execution, Deployment. Then click Debugger. Under the title Android Debug Bridge check the use libusb backend checkbox and hit apply. Now retest the link.

May be you are missing buildToolsVersion in .gradle file.
Also hit the link with your applink.json hosted domain name change in https://digitalassetlinks.googleapis.com/v1/statements:list?source.web.site=<your-applink-hosted-domain>&relation=delegate_permission/common.handle_all_urls
Let me know if this fixes your issue.

Basically, there is a problem in the App Link Assistant itself. After successful link and verification process, it shows this error once in a while. But if you try again, it will be success. No need to worry. Just test in the actual phone and it should work fine.

Related

App Link is not working for Android instant app

I have updated my current play store app with the Instant app appLink feature. But the link is still not working after waited for 4 days.
I have created link with below steps.
Tools -> App Links Assistants
Followed all the steps and Verify that link in android studio.
It verified successfully.
I have added a dependency in app-level Gradle: implementation "com.google.android.gms:play-services-instantapps:17.0.0"
To enable instant app right-click on app module -> Refactor -> Enable instant app support.
Increment a version code to 1 and uploaded a new build on the play store.
Could you guys please help me out to find out the missing element or a direction?
Have you followed the below developer guide for the app asset link?
https://developer.android.com/training/app-links/verify-site-associations
In that, they have mentioned the steps which have to address accordingly.
Also, you can confirm that the Digital Asset Links JSON file is properly hosted and defined using the below URL:
https://digitalassetlinks.googleapis.com/v1/statements:list?source.web.site=https://domain.name:optional_port&relation=delegate_permission/common.handle_all_urls

Android studio Firebase and Github pushing and cloning

I have created a small project for user register and login in(Authentication) android studio using firebase and it was working fine. Basically i need to keep this project on github, I have moved to project to my desktop and then pushed it to github. My version of the project works, however, the cloned project doesn't seem to work as it just keeps loading when the user wants to register or login.
Also, it comes up with some errors like missing iml's or that the app has multiple slice apk's and need to uninstall.
My question is what steps do I need to undertake to make sure that the application will work when pushed to a github repo and then cloned back from the repo, so that the application runs when downloaded on any pc, and do i have to do anything to the firebase?
since what i see is that everything is in place, package name hasnt changed, all files and dependencies are present.
First of all you didn't specify what authentication you are using. For example if you are using facebook you need to add to the Facebook developers page the sha1 key fingerprint for each device you are going to install the app.
Secondly I have deployed my firebase project to github and working from my mac and windows machine without any problem syncing with Firebase. In firebase project settings as I can see I haven't added any SHA certificate fingerprint.
Make sure that you have added on Github all the SHA certificate fingerprint from any pc that you are planning to clone the project.
First of all i was using Email and password authentication.
Secondly the issue was that the google play was not updated inside of the emulator.
For anyone that runs into the same problem click the three dots at the bottom of the emulator panel and go into "Google Play" and update.
Hope this helps someone!

Is there another place to get a google-services.json?

I tried clicking the GET A CONFIGURATION FILE link from the docs, but the resulting page just loads and loads. This happens in Firefox and Chrome and on my phone. Is there some other way to get a config file?
EDIT: I am getting these errors in Chrome Dev Console:
Refused to display 'https://accounts.google.com/ServiceLogin?service=cloudconsole&osid=1&passiv…ed%253Dtrue%26cntlbl%3DContinue%2BAdding%2BSign-In%26cntapi%3Dsignin&hl=en' in a frame because it set 'X-Frame-Options' to 'DENY'.
Failed to execute 'postMessage' on 'DOMWindow': The target origin provided ('https://console.developers.google.com') does not match the recipient window's origin ('null').(anonymous function) # script_foot.js:348n.event.dispatch # jquery.min.js:3r.handle # jquery.min.js:3
This might be a temporary issue due to network connectivity or something like that.
One solution would be to try again at a later point in time. This might be happening because you're trying to download the google-services.json for the sample project (com.google.samples.quickstart.signin).
If you want result now, you could follow the steps to integrate the Google Sign In into your app.
Create a new empty android studio project/if you have an existing
project skip this step.
Use this link and follow the onscreen instructions to generate the google-services.json for your app.
The app name here refers to your project name in Google Developers
Console. If you've already setup your Google developers console
project for your android app, you can select that via the drop-down
menu. If you have not created one, just enter a name and that
project will be created for you in your developers console.
Select the google services you need for your project viz Google Sign
In, Google Cloud Messaging, AdMob etc. In our case, we just selected
Google Sign In.
You will be asked for SHA-1 hash. Follow these steps to get one.
Click on generate configuration files. Next screen you will be presented with an option to download google-services.json for your app. Download that and you're good to go.
Once you have the google-services.json, follow these steps to complete the Google Sign In.
References
Start Integrating Google Sign-In into Your Android App,
Integrating Google Sign-In into Your Android App.
You will get "google-services.json" as soon as you create a Firebase project.
But, in case you missed and forgot to download that, you can still get the JSON file from the existing project-
Just select the project from firebase console.
Head over to project settings
scroll down (Yeah!, there it is!)
Screenshot :
OK, I've found a workaround if anyone else is having this problem.
Based on the error message about being unable to display https://accounts.google.com/ServiceLogin?service=cloudconsole&osid=1&passiv…ed%253Dtrue%26cntlbl%3DContinue%2BAdding%2BSign-In%26cntapi%3Dsignin&hl=en in a frame... I just followed that link directly.
EDIT: None of the other links were working for me. If you came searching for the console errors Refused to display..., this is the answer for you. This bug seems to have been fixed for the google-services.json, so if you're just looking for the link, the highest-rated answer is the one you want.
Referring to this page:
The Firebase console will help you download the google-services.json. In addition, the Quickstart guides for most APIs have instructions for generating this file. Once you have downloaded the google-services.json file, copy it into the app/ folder of your Android Studio project, or into the app/src/{build_type} folder if you are using multiple build types.
So go to Firebase Console, press add new project and follow instructions

Fabric plugin cannot login via Android Studio

I am using Android Studio 1.5, Fabric Plugin 2.3.1. What possible reasons would Fabric not allow me to login?
The whole process is completely knackered. Any Fabric link I visit including the organization settings link located here directs me to the on-boarding link where all I can do is view instructions on how to download the plugin. I have installed the plugin, login and I see the list of Fabric components for about 2 seconds before it brings me back to the login screen with no message at all.
The credentials are fine (incorrect credentials give me an orange message saying so). I have tried it with 3 different accounts.
So now I am in a situation where I have 3 accounts, all of which only allow me to view instructions on how to download the plugin, and the plugin will not let me get further than the login screen. I could do this manually but cannot access the organization settings screen either. Any ideas?
EDIT: This is the closest similar issue I could find on their forums but it relates to a Mac (I'm on Windows 10, Java version jdk1.7.0_79)
What fixed it for me was adding the authKey to the application block in the main manifest.
NOTE: at the time of this issue, I am using Android Studio 2.0 Beta 6. We believe that there might be an issue with the Fabric plugin and this version.
To see what's happening to the Fabric plugin, I had to open the Console app and view the logs in realtime. Sure enough, it showed that was authenticated with my credentials, AND it passed back the reason I was being sent right back to the login: Missing authkey in the application block.
So I copied an authkey node from a previous project and added it to the manifest and bingo - it took me to the screen to install Crashlytics.
The thing is, I could have sworn that the Plugin was supposed to GIVE me the authkey after it installed Crashlytics, so I was a bit puzzled as to why this worked. But it did.
Again, this is with Android Studio 2.0 Beta6 so it might be only related to that. But using the Console to diagnose the issue with the Fabric Plugin is the take away here.
Download the fabric plugin for android studio via jetbrains.com using your prefered browser(i.e mozilla,chrome etc).
after your file get downloaded(not via andriod studio), open your AndroiStudio, goto --file>>settings>>plugin>>install plugin from disk, give the .jar file which you have downloaded, then restart studio

Deploy to App Engine trouble - You must be logged in to perform this action

I am new to Android Studio and have just runned through the tutorial
https://github.com/GoogleCloudPlatform/gradle-appengine-templates/tree/master/GcmEndpoints
without much trouble.
However, when I try to deploy my backend to the app server it promts me: "You must be logged in to perofrm this action".
I have no idea of why it teels that. I can easely find me project on the list, and Im logged in to my google acount on various browsers including Chrome.
Have seached the internet, but found no one else with the problem before.
Best Regards Allan
It's possible that your auth has been done a little while ago and the system cannot properly see you authenticated anymore, which would explain such a behavior.
At the bottom of the list of projects, you should see a "add account" button. Click on this and just re-auth. Should clear the bad tokens :).
Steps For Intrgration of App Engine Endpoints Module.
.....................................................
1-:Create an Google Devloper Console Account.Create a new project after completing the project creation they give you a Project id and project no.
2-:Open Android Studio File-->New-->New Project.
3-:After Project creation is completed Right Click On your project select Module-->Google Cloud Module as shown in images folder chouse_module image.
4-:When you Select The Google Cloud Module Then choose "App Engine Java Endpoints Module".as shown in images folder endpoints image.
5-:As soon as the backend module is added to your project and Gradle sync finishes,a new run configuration with your backend's module is created.
6-:Rebuild your project via "Build → Rebuild Project"
7-:Now Check Your Backend started sucesfully naivigate to http://localhost:8080.if your Backend started sucessfully you saw the screen as as shown in images folder devappserver-endpoints image.
Connecting your Backend to your android project.
...........................................................
8-:After Backend Module is created and added strong libraries is automatically genrated for you.
9-:To start sending requests to the added Cloud Endpoints backend API.you Have to created one Async Class in your Project file.you Can Get the Async task class in required Packages folder with name AsynctaskClass.java
10-:To make the actual call, invoke this AsyncTask from one of your Android activities.In this way :: new EndpointsAsyncTask().execute(new Pair(this, "Message"));
11-:Ckeck that you granted an internet permission in menifest or not.
12-:Now check that you have accese to local host as shown in point 7.
13-:Its time to Check in Emulator Change your Run confrigation and run your project If everything goes well, you should see the following toast in your app as shown in images folder emulator-Toast image.
Deploying the backend live to App Engine
......................................................
14-:If your backend is working locally, you can deploy it to Google App Engine.
Stop the backend, if it is running locally, by selecting Run > Stop.
Than navigate to Build > Deploy Module to App Engine.
15-:update your src/main/webapp/WEB-INF/appengine-web.xml file's property and replace myApplicationId with the ID of the project that you just created.as shown in point 1.
16-: you can see the screen as shown in images folder deploy-image image.
17-:In the Deploy to you have to select the project you created on Google Devloper Console.as shown in point 1.
18-:Put the version name and click deploy Button.
19-:Once you have deployed your backend to App Engine, you can connect your Android app to it by modifying AsyncTask class defined in point 9 replace the perticular lines shown in ReplaceCode.java file in required Packages folder.
20-:Now you can communicate with your new App Engine backend!.
For More Info -:
https://github.com/GoogleCloudPlatform/gradle-appengine-templates/tree/master/HelloEndpoints.
https://cloud.google.com/tools/android-studio/app_engine/add_module?hl=en.
Ive never used android studio but Im sure its like eclipse sdk puglin.
There is an easy way to deploy ur apps on ur mobile device, but before u get to that point u need to eanable android mobile on debug mode (On settings,developer options).Once u have done that, Im pretty sure there is an option which lets u run ur app on android device making much smother than doing it virtual app.
Hope I helped ya...
Use the gradle commands.
Open the terminal within android studio and run
gradlew appengine:update
Or navigate to the gradle project window and look for the google appengine folder under your backend. And double click the appengineUpdate command.
Adding the backend with android studio should automatically add the appengine plugin for gradle in your backend build.gradle file like this. This plugin is allows you to run the appengine update command.
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.google.appengine:gradle-appengine-plugin:1.9.18'
}
}
I was facing similar issue using Android Studio Ver2.2 in Ubuntu 14.04
I was not able to do sign-in into Android Studio using the SignIn icon from top-left of the Android Studio IDE. When signin icon clicked, a pop-up says that Sign-in using external browser but nothing would pop-up.
Build->Deploy to app Engine->Deploy to tab was also showing the same message as above but no browser would pop up
Even gradlew api:appengineUpdate was not working. (no browser would pop up).
Problem got resolved by changing the File->Setting->Web Browsers (it was listing browsers Chrome, Firefox, Safari in that order). The Default Browser was set to "First listed". I unchecked the chrome and my problem got solved, I was able sign-in and deploy my project.
I spent lot of time finding solution for this, thought it might help others, so posting it.
I had the same issue.
I did not realize it at first but when you get this message, you simply click on the dropdown "Deploy To", and then it invites you to log into your google account.
It is not very intuitive if your project is already selected by default.

Categories

Resources