React Native Android azure build failing randomly - android

Azure pipeline is trying to download a resource from 'https://dl.bintray.com/microsoftazuremobile/SDK/'.
The same thing had been working for a year so Gradle config doesn't seem an issue but for a week now it is failing randomly.
Actual error :
> Could not get resource 'https://dl.bintray.com/microsoftazuremobile/SDK/com/huawei/hms/update/2.0.6.302/update-2.0.6.302.pom'.
> Could not GET 'https://dl.bintray.com/microsoftazuremobile/SDK/com/huawei/hms/update/2.0.6.302/update-2.0.6.302.pom'. Received status code 502 from server: Bad Gateway
Any ideas how to fix?

Seems like the repo has been moved and docs are not updated.
Changed the repo from bintray to mavenCentral
- maven { url 'https://dl.bintray.com/microsoftazuremobile/SDK' }
+ mavenCentral()
It works perfectly

Related

Unable to make a pull in gradle file

i´m trying to make a task in Gradle for my Android project ( using Kotlin DSL ) where I need to do an automatic pull for my "develop" branch.
This are the commnand I want to run :
git pull origin develop:develop
In the terminal this works just fine.
I`m using "commandLine" with "exec" in my gradle file and I´m having this error message:
code:
tasks.register<ReleaseTask>("makePull") {
exec { commandLine("git", "pull", "origin develop:develop") }
}
error message:
ssh: Could not resolve hostname origin develop: nodename nor servname provided, or not known
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
FAILURE: Build failed with an exception.
I don´t have any issue if I try this commands in the terminal, do you know what i´m doing wrong ?
You haven't separated the origin and the develop:develop arguments in the gradle version. Use this instead:
commandLine("git", "pull", "origin", "develop:develop")

SPLUNK MINT throwing ssl error in Android studio

when I run my program its throwing "ssl error" and "remote host terminated the handshake".
Currently I am using the below library in build.gradle. I have tried upgrading to 5.2.5 but in its website it shows they have stopped the service. Even tried other methods but nothing worked. How can I solve this?
repositories
{
url "https://mint.splunk.com/gradle/"
}
dependency
{
implementation 'com.splunk.mint:mint:4.4.0'
}
1)Tried adding
System.setProperty("https.protocols", "TLSv1,TLSv1.1,TLSv1.2");
removed .gradle and .idea and ran the code
changed the sdk
accept non-trusted certificates automatically
added
systemProp.http.proxyHost=x
systemProp.https.proxyPort=y
systemProp.https.proxyHost=x
systemProp.http.proxyPort=y
but this throws error as x is not recognised

Code does not build succesfully when integrating Azure Push Notifications

My code worked fine until 2 days ago when it stopped building and started showing the following error.
Could not GET 'https://dl.bintray.com/microsoftazuremobile/SDK/androidx/navigation/navigation-safe-args-generator/maven-metadata.xml'.
Received status code 502 from server: Bad Gateway
I found that the culprit is the following line of code in the 'repositories' section of build.gradle file.
maven { url "https://dl.bintray.com/microsoftazuremobile/SDK" }
If i remove this line, the build is successful again. I have tried opening this url in browser and it gives 502 bad gateway error. I have heard that bintray will stop working , but i am not sure. Incase its true, i could not find any replacement of this line in the Azure Sdk Integration document.
Can someone please help resolving this issue. Thank you

Android simulator can't start the app during running test with Detox

I want to test our app with detox. On IOS it works fine, but it doesn't work yet on Android.
So when I run the detox test the simulator will open, but the app won't be started. In the logs is stated that the build was successful. Besides that when the test have failed, I can open the app on the simulator and everything works. (The tests are not ready started yet, they are in the setup fase when the issue happens)
This is the error message I get:
DetoxRuntimeError: Failed to run application on the device
HINT: Most likely, your tests have timed out and called
detox.cleanup() while it was waiting for "ready" message (over
WebSocket) from the instrumentation process.
at EmulatorDriver._getInstrumentationCrashError (/Users/corinejanssen/PycharmProjects/de-selfcare/frontend/node_modules/detox/src/devices/drivers/android/AndroidDriver.js:175:12)
at EmulatorDriver.instrumentationCloseListener (/Users/corinejanssen/PycharmProjects/de-selfcare/frontend/node_modules/detox/src/devices/drivers/android/AndroidDriver.js:142:67)
at EmulatorDriver._terminateInstrumentation (/Users/corinejanssen/PycharmProjects/de-selfcare/frontend/node_modules/detox/src/devices/drivers/android/AndroidDriver.js:166:12)
at processTicksAndRejections (internal/process/task_queues.js:97:5)
at async ChildProcess. (/Users/corinejanssen/PycharmProjects/de-selfcare/frontend/node_modules/detox/src/devices/drivers/android/AndroidDriver.js:266:7)
{ name: 'DetoxRuntimeError' }
Versions I use:
Detox: 16.2.0
jest: 25.0.1
node: 12.16.0
Is someone who has this issue and solved it?
I solved this issue, by trying a lot of things. I think it was related to a missing dependency in the android/build.gradle.
For the exactness I put all the dependencies we add to this file:
dependencies {
classpath "com.android.tools.build:gradle:3.4.2"
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
classpath "org.jetbrains.kotlin:kotlin-android-extensions:$kotlin_version"
}

Bitbucket : The requested URL returned error: 402

I changed password on bitbucket, and now Android Studio can't make push error on Event Log:
Push failed: Failed with error: fatal: unable to access 'https://USERNAME#bitbucket.org/USERNAME/REPOSITORY.git/': The requested URL returned error: 402
How to solve it?
This just happened to me and the fix was to remove some users from my repositories.
Bitbucket's free plan comes with unlimited private repos so, deleting your repos may not have any effect. However, you can only add a maximum of 5 users with the free plan.
This server response is due to the fact that you have exceeded the free limit for Bitbucket. You have two options:
Upgrade your Bitbucket server license
Delete some old repos you don't need anymore.

Categories

Resources