Connection timed out when pulling dependencies

#1

Bitrise Build Issue Report template

Description of the issue

Several times per week we run into an issue where the dependencies of our app build are not able to be pulled properly.

The error normally looks something like this:

Connect to repo.maven.apache.org:443 [repo.maven.apache.org/151.101.200.215] failed: Connection timed out (Connection timed out)

Environment:

Ubuntu environment doing Android builds

If on Bitrise.io: which stack? If not on Bitrise.io: on what operating system? (Plus any other information you can share)

The step that fails is a script step that calls into Fastlane. The command fastlane is running looks like the following:

/bitrise/src/gradlew :[REDACTED]-api:test

Reproducibility

  • Does a “Rebuild” help? (You can trigger a rebuild from the Build’s page, by clicking the “Rebuild” button in the top right corner of a finished build) : YES/NO
  • Does a rebuild without caches help? (You can remove the Cache:Pull and Cache:Push steps temporarily to not to use the cache, or you can delete all the caches on the Settings tab of the app. : YES/NO
  • Does the issue happen sporadically, or every time? :
  • Does upgrading the build Step to the latest version help? : YES/NO
  • When did the issue start? :

A rebuild helps and normally solves the issue. This issue is more annoying than anything because it’s viewed as a false negative meaning the build seems to fail outside of our control.

We don’t currently have build caching enabled so this is not relevant to this specific issue.

The issue is sporadic and have not found any rhyme or reason when it does.

Upgrading the build step does not help the issue.

This issue has been plaguing us for a few months now. As mentioned it’s easily solvable by doing a rebuild but we would like to get it cleared up.

Local reproduction

Can it be reproduced on your own Mac/PC by following our local debug guide? Please follow at least the first section (“Testing with a full clean git clone”) to make sure to test the state of the code what bitrise.io will get when it does a git clone in the clean environment! If possible please note which sections you tried.

This issue is not reproducible locally. I have never failed to pull down dependencies locally unless I know of an issue with JCenter, Maven, etc.

Local reproduction: Linux / Android (docker based) stack builds

Can it be reproduced by running the build locally, after doing a new git clone of the repository into the /tmp directory and running the build from there with the Bitrise CLI ( https://www.bitrise.io/cli )? If no, can it be reproduced with Docker (using the same docker images / environment we use on bitrise.io)? Related guide: http://devcenter.bitrise.io/docker/run-your-build-locally-in-docker/ .

It’s possible that it’s reproducible in that scenario but I would need to run a lot of builds to see if that’s the case.

Build log

Please copy paste the build’s bitrise.io URL here (or if the issue happens somewhere else then the full logs), or if you can’t share the url / log here then send the url or full log through a private channel (e.g. email - https://www.bitrise.io/contact ), with a link to the related Discuss issue.

This is an example of how the builds fail, but this specific endpoint/dependency is not always the one that causes us trouble. It seems to change often which dependency fails to be downloaded.

0 Likes

#2

Hello @vince.delricco

Did you try to rebuild it since this happened? did it occur again?

0 Likes

#3

Hi there @fehersanyi-bitrise. Yeah, as mentioned in the issue writeup:

A rebuild helps and normally solves the issue. This issue is more annoying than anything because it’s viewed as a false negative meaning the build seems to fail outside of our control.

The problem is that this type of error happens frequently enough that sometimes we need to rebuild several times per day (other days this issue doesn’t happen at all).

0 Likes

#4

Hi @vince.delricco!

Could you try to see if this issue is also occurring on the Hybrid stacks - or if they are specific to the Linux based ones?

0 Likes