[Android][cyanogenmod 12.0] Source syncing 403 error [duplicate] - android

This question already has answers here:
Pushing to Git returning Error Code 403 fatal: HTTP request failed
(74 answers)
Closed 6 years ago.
I am syncing sources of cm12 but facing some problem like
1. I am using repo sync -f command for syncing
it shows syncing complete but most of the folders are missing as vendor,device,platform prebuilts and packages but they appeared in the .repo folder
there are some errors when it is syncing packages
*Fetching project CyanogenMod/android_packages_apps_UnifiedEmail
error: The requested URL returned error: 403 while accessing https://github.com/CyanogenMod/android_packages_apps_UnifiedEmail/info/refs
fatal: HTTP request failed***
I tried to solve this by changing the manifest.xml but no success
how to solve it.
Any help would be appreciated

I had a similar problem fetching CM9. Following the advice found here, particularly the use of repo sync -j1, I was able to isolate the problem to android_external_svox, which was taken down due to a DMCA violation. I went back to the original manifest.xml file, edited out that one line, and the sync finished without error. more details here.

Related

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

Git repo sync - connection lost

I'm trying to download android source (Cyanogenmod). i have spent more than 12hrs to download 2.5GB files, Now my connection lost for a while, it shows
error: RPC failed; result=56, HTTP code = 200
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
fatal: unable to access 'https://android.googlesource.com/platform/prebuilts/misc/': Could not resolve host: android.googlesource.com
fatal: unable to access 'https://github.com/CyanogenMod/android_packages_inputmethods_LatinIME/': Could not resolve host: github.com
fatal: unable to access 'https://android.googlesource.com/platform/prebuilts/misc/': Could not resolve host: android.googlesource.com
error: Cannot fetch CyanogenMod/android_packages_inputmethods_LatinIME
error: Cannot fetch platform/prebuilts/misc
error: Exited sync due to fetch errors
Can i resume the download or i should download from the beginning, please help me to resume my download.
Thank you!
Once you have applied the fix that I describe below, you should simply re-run repo sync in order to resume and fully complete the resource synchronization process that was interrupted by these fatal errors.
The solution to the DNS-related error that you've encountered [fatal: Could not resolve host] is detailed on the Known Issues resolution page at Google's AOSP Developer Site. Apply this fix by adding the appropriate host entry for your remote repository android.googlesource.com inside your development machine's /etc/hosts config file. Begin by clicking here and here to execute the IP address lookup tool provided by the free web resource: http://network-tools.com/nslook/.
Google's full description of this issue with detailed resolution I've included here:
Difficulties syncing the source tree (DNS issues).
Symptom: When running repo sync, the process fails with various errors
related to not recognizing the hostname. One such error is
<urlopen error [Errno -2] Name or service not known>.
EDIT: Another fatal error might be Could not resolve host.
Cause: Some DNS systems have a hard time coping with the high number
of queries involved in syncing the source tree (there can be several
hundred requests in a worst-case scenario).
Fix: Manually resolve the relevant hostnames, and hard-code those
results locally.
You can resolve them with the nslookup command, which will give you
one numerical IP address for each of those (typically in the "Address"
part of the output).
$ nslookup googlesource.com
$ nslookup android.googlesource.com
You can then hard-code them locally by editing /etc/hosts, and adding two
lines in that file, of the form:
aaa.bbb.ccc.ddd googlesource.com
eee.fff.ggg.hhh android.googlesource.com
Note that this will only work as long as the
servers' addresses don't change, and if they do and you can't connect
you'll have to resolve those hostnames again and edit etc/hosts
accordingly.
You don't resume a clone, you can try a shallow clone instead.
As mentioned here:
Error code 56 indicates a curl receive error of CURLE_RECV_ERROR which means there was some issue that prevented the data from being received during the clone process.
Typically this is caused by a network setting, firewall, VPN client, or anti-virus that is terminating the connection before all data has been transferred.
You can know more with:
set GIT_TRACE_PACKET=1
set GIT_TRACE=1
set GIT_CURL_VERBOSE=1
You can try changing http.postBuffer or switching to ssh url clone.
Spartan i checked the Cyanogenmod its working normally i prefer use internet download manager.i download 60mp and recall it.successfully fetched and resumed.
Could not resolve host: android.googlesource.com
Which could be a DNS server problem. Try first restarting your modem in order to flush its DNS cache. If you're still seeing the problem, try changing your Primary DNS to either one these two publicized DNS servers that Google operates:
8.8.8.8
8.8.4.4
Note that, if your Primary DNS has already been configured as described and you've also long-rebooted the router without resolution (pun intended), then adjusting your Primary DNS configuration to point at other public DNS servers is not likely to fix your situation. However, a reputable list of no-cost public servers can be found here.

Android SDK Manager - Failed to fetch

Error 1:
Failed to fetch URL http://dl-ssl.google.com/android/repository/addons_list-2.xml, reason: Unknown Host www.google.de
Error 2:
Failed to fetch URL http://dl-ssl.google.com/android/repository/repository-10.xml, reason: IO Unknown Host www.google.de
Can I download and insert this xml files manually?
Are then this problems solved?
There are some people who has posted about downloading SDK tools without SDK manager.
Like in this site.
But you should check your internet connection. I have same problem but after that i came to know that it was because of bad internet connection.
I have retried it and it was downloaded successfully.
I encountered the same problem and here is what I did to solve the problem.
Since I use proxy server for accessing internet i have edited the file
"C:\Users\.AndroidStudio\config\options\other.xml" as
Notice the PROXY_HOST value there is no "http://" part, this is important. In my case when I insert that it did not work I did not know why.
2. I have edited the file
"C:\Users\\AppData\Local\Android\sdk\tools\android.bat"
I have changed the line at the end of android.bat file from
call "%java_exe% %REMOTE_DEBUG%" ....
to
call "%java_exe% **-Djava.net.preferIPv4Stack=true** %REMOTE_DEBUG%"...
Notice the value in bold

Error deploying artifact: Failed to transfer file Return code is: 401

I am trying to upload my library, ListBuddies, to maven. To do that I am using the gradle-mvn-push github project of #ChrisBanes . I follow all the steps that he mentioned on his repo plus some others that are needed before that repo is used:
I opened a Jira issue and I waited until It got resolved
I have created GPG keys
I configurate ListBuddies's build.gradle files and the gradle.properties
I have created another local gradle.properties at "/Users/jpardogo/.gradle/gradle.properties"
local gradle.properties file (signing keys are only need for release so should not be a problem for the SNAPSHOT):
//These are the username/password that I use for:
//[JIRA](https://issues.sonatype.org)
//and [NEXUS](https://oss.sonatype.org
NEXUS_USERNAME=jpardogo1
NEXUS_PASSWORD=jira-pass
//This is the key ID that I obtain doing "gpg --list-keys" on the terminal
signing.keyId=my-keyid
//This is the paraphrase I set when I first created the key
signing.password=my-paraphrase
//That's the path to my secret key ring
signing.secretKeyRingFile=/Users/jpardogo/.gnupg/secring.gpg
Look like everything is setup properly but when I do:
gradle clean build uploadArchives
At the end I receive code ERROR 401:
:library:uploadArchives
Uploading: com/jpardogo/listbuddies/library/1.0.0-SNAPSHOT/library-1.0.0-20140209.151716- 1.aar to repository remote at https://oss.sonatype.org/content/repositories/snapshots/
Transferring 67K from remote
:library:uploadArchives FAILED
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':library:uploadArchives'.
> Could not publish configuration 'archives'
> Error deploying artifact 'com.jpardogo.listbuddies:library:aar': Error deploying artifact: Failed to transfer file: https://oss.sonatype.org/content/repositories/snapshots/com/jpardogo/listbuddies/library/1.0.0-SNAPSHOT/library-1.0.0-20140209.151716-1.aar. Return code is: 401
* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
BUILD FAILED
I have been looking for an answer the whole day of yesterday and today as well but I couldn't solve it. The error 401 reason is good explain in here, but I couldn't solved anything and I also read that It could be due user permissions problem although I register on Jira as the guide says.
I hope you can help me with that and If you need any more information, please let me know. Thanks.
EDIT: I want to update the question with the link to the jira ticket and its comments.
I finally solved it. All the configuration was ok. The problem was on the file gradle.properties. Because I copy paste the structure of the file, a hidden tabulation reminded next to the NEXUS_USERNAME, so the username actually was being sent with the tabulation and I was receiving a authentication error.
Sometimes things are more simple than you think, and you don't see them. The first thing I will do the next time will be to check the format of the files.
I had exactly the same problem, and the reason was: my password (generated) contained a backslash \.
Solution: Backslashes need to be escaped in gradle.properties!
Example:
ossrhPassword=partBeforeBackslash\\\\partAfterBackslash
instead of:
ossrhPassword=partBeforeBackslash\partAfterBackslash
For me the problem was that I was uploading a version that already exists in the rep. The solution was just to change the 'version' in the build.gradle file.

Android SDK can't fetch XML and ArrayIndexOutOfBounds Exception in Project Run

I have two problems with android SDK.The first is that after installing sdk manager I can not install new plateform,tools,sysimage etc online it gives following error:
Fetching
Validate XML
XML verification failed for .
Line -१:-१, Error: org.xml.sax.SAXParseException: schema_reference.4: Failed to read schema document 'null', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <>.
Fetched Add-ons List successfully
Fetching URL:
Validate XML:
XML verification failed for .
Line -१:-१, Error: org.xml.sax.SAXParseException: schema_reference.4: Failed to read schema document 'null', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <>.
Fetching URL:
Validate XML:
Failed to fetch URL , reason: addon.xml
Done loading packages.
I tried force https.
http in place of https.
I am using DSL for internet and not using any proxy to connect to internet.
For the sake of removing this problem I also tried proxy server but all in vain.
So I installed all the updates offline APD v2 helped me with downloading.
I used both Eclipse and Netbeans for dev.Everything worked fine,until I tried to run a new project and even sample project.
On Eclipse it gave me following error:
Same problem was with netbeans:
Creating redLight-debug-unaligned.apk and signing it with a debug key...
D:\Android\android-sdk\tools\ant\build.: The following error occurred while executing this line:
D:\Android\android-sdk\tools\ant\build.: The following error occurred while executing this line:
D:\Android\android-sdk\tools\ant\build.:
com.android.sdklib.build.ApkCreationException: java.lang.ArrayIndexOutOfBoundsException: 13
I am new in android app development and trying to rebuild my Java Application for android platform,but I am stuck in first step.
Please help me here.
Solution for your first problem is simple : Line -१:-१, it shows u r language for windows os is set to hindi (IN_HI).
Goto Control panel region & language option change language to English for all formats.
Restart machine & fetch xml.
I am also facing second problem solution to that is not yet found
check this: https://groups.google.com/forum/?fromgroups#!topic/android-developers/BvO5g6RMamo
Also I have updated bug in Android issues :
http://code.google.com/p/android/issues/detail?id=28824

Categories

Resources