as per https://mailchi.mp/3d439eeb1098/travis-ciorg-is-moving-to-travis-cicom , we need to do this before the end of 2020
migrating is super easy: https://docs.travis-ci.com/user/migrate/open-source-repository-migration/#the-migration-steps
a little while ago I went to https://travis-ci.com/organizations/scala/migrate and migrated almost every scala/* repo
I intentionally left out our most critical repos: scala/scala, scala-dist, scala-dist-smoketest. I figured we could get them in a second round later, if the first round seems okay. I see travis-ci.org references in scripts/common and README.md. we might want to wait until after 2.12.13 and 2.13.4 are both out
can anyone think of anywhere else we'll need to update any links or anything?
@sjrd could the Scala Center and/or LAMP take care of docs.scala-lang, scala.epfl.ch, scala-lang, and vscode-scala-syntax?
Yes, that shouldn't be a problem.
scala/scala, scala-dist, scala-dist-smoketest
we'll need to fix some scripts there
https://github.com/scala/scala/blob/30fd6009669171f7dc36af57aa045fa4ac821c97/scripts/common#L187
https://github.com/scala/scala-dist/blob/4218dfc75b9e2a5310b7abde28d3d6ba8e611601/scripts/common#L17
https://github.com/scala/scala-dist/blob/4218dfc75b9e2a5310b7abde28d3d6ba8e611601/admin/build.sh#L65
We probably want to migrate scala/scala after the upcoming releases.
@ignasi35 points out that branch protection rules may need to be updated when a repo is migrated
Ouch, new pricing model for Travis, which also impacts the free OSS usage:
https://blog.travis-ci.com/2020-11-02-travis-ci-new-billing
It's bad. I believe this means we'll have to migrate to something else instead, perhaps GitHub Actions.
Perhaps we needn’t be so pessimistic so soon. The blog post makes reference to abuse — you can imagine people doing Bitcoin mining or whatever under cover of OSS. We’re an established, reputable organization — I think there’s a strong chance that if we asked they’d say “yes of course, you’re exactly who we want to support” with free runs.
There might be other reasons to ultimately migrate, but I think it’s at least worth asking, so then we wouldn’t be under any time pressure.
I think while we're _haven't_ migrated, we're not burning those precious 1000 minutes. So we shouldn't migrate until we know that Travis CI is happy for our builds to continue to run on their service, as an OSS project.
I've been migrating all the projects I'm involved in to GitHub Actions, and it's been pretty easy, and I'd say it's more featureful than Travis CI.
I don't see any good reason to playing a game of chicken with Travis CI's end-of-year deadline since I don't think they really care. I'm thankful to years of their services, but giving out CPU minutes and cache network transfer for free probably wasn't sustainable even without supposed Bitcoin miners etc. GitHub on the other hand feels much more stable in that sense since Microsoft can make a long-term play.
We have now moved all scala/* repos except scala/scala-dist/scala-dist-smoketest . Those three repos, we'll move after 2.12.13 is released. (Our publishing is currently Travis-based, so we don't want to risk disrupting the release.)
Let's reserve this ticket just for the travis-ci.org to travis-ci.com migration, which we're going through with for now, even if we end up doing something else longer-term.
For broader discussion around other changes we might make after that, I wrote up the current situation at https://github.com/scala/scala-dev/issues/751, let's continue there.
I pulled the lever on the last three repos today.
scala/scala PR validation seems to be working, for example at https://travis-ci.com/github/scala/scala/builds/210295371
note to self: once I get all this working on 2.13.x, don't forget to backport it to 2.12.x
unsurprisingly, mergely builds are failing, at e.g. https://travis-ci.com/github/scala/scala/jobs/464005404 we see
$ triggerScalaDist
failed to
failed to... failed to what? failed to prosper.
UPDATE: https://github.com/scala/scala/pull/9411
UPDATE: https://github.com/scala/scala-dist/pull/209
UPDATE: https://github.com/scala/scala-dist-smoketest/pull/29
even after scala/scala#9411, at https://travis-ci.com/github/scala/scala/jobs/464049381 we see:
$ triggerScalaDist
failed to start job
which is coming from triggerScalaDist in scripts/common in this repo
according to https://docs.travis-ci.com/user/developer/ , Travis-API-Version: 3 remains current
perhaps we need a new TRAVIS_TOKEN
created a token at https://github.com/settings/tokens and gave it permissions as outlined at https://docs.travis-ci.com/user/github-oauth-scopes/
brew install travis
travis login --com --github-token ...
travis token --com
which then prints a token (it's the same every time) which I used here:
travis encrypt TRAVIS_TOKEN="..."
and then I pasted that into .travis.yml and pushed it up to GitHub: scala/scala@98acd0f0fdcbcc19e6263157dc0167755f6ce83e
resulting in this job: https://travis-ci.com/github/scala/scala/builds/210317889
at which we see
$ triggerScalaDist
The command "triggerScalaDist" exited with 0.
Yay!
and in fact it did trigger this job: https://travis-ci.com/github/scala/scala-dist/builds/210320177
which then failed with
+local 'jsonTemplate={ "request": { "branch": "%s", "message": "Smoketest %s", "config": { "before_install": "export version=%s scala_sha=%s" } } }'
++printf '{ "request": { "branch": "%s", "message": "Smoketest %s", "config": { "before_install": "export version=%s scala_sha=%s" } } }' 2.13.x 2.13.5-bin-98acd0f 2.13.5-bin-98acd0f 98acd0f0fdcbcc19e6263157dc0167755f6ce83e
+local 'json={ "request": { "branch": "2.13.x", "message": "Smoketest 2.13.5-bin-98acd0f", "config": { "before_install": "export version=2.13.5-bin-98acd0f scala_sha=98acd0f0fdcbcc19e6263157dc0167755f6ce83e" } } }'
++curl -s -o /dev/null -w '%{http_code}' -H 'Travis-API-Version: 3' -H 'Authorization: token [secure]' -H 'Content-Type: application/json' -d '{ "request": { "branch": "2.13.x", "message": "Smoketest 2.13.5-bin-98acd0f", "config": { "before_install": "export version=2.13.5-bin-98acd0f scala_sha=98acd0f0fdcbcc19e6263157dc0167755f6ce83e" } } }' https://api.travis-ci.com/repo/scala%2Fscala-dist-smoketest/requests
+local curlStatus=403
+[[ 403 == \2\0\2 ]]
+echo 'Failed to start travis build'
Failed to start travis build
+exit 1
presumably this is just the same problem where I need to replace Lukas's .org token with a new .com token
travis token --com is the same every time, but I re-ran travis encrypt on it (the encryption is repo-specific, naturally), pushed https://github.com/scala/scala-dist/commit/e40fd600290064904b93f9dd64149022618a2334
new runs:
yay, all good
@lrytz I mentioned a couple hours ago that I thought we should run through the release steps and see if anything goes wrong, stopping before the “point of no return”, of course... but actually, now that I look at it, I think there's nothing we can do there that would prove anything we haven't already proven
so I think this is actually done once I backport to 2.12.x. the next time we release we should just pay extra close attention.
Most helpful comment
I think while we're _haven't_ migrated, we're not burning those precious 1000 minutes. So we shouldn't migrate until we know that Travis CI is happy for our builds to continue to run on their service, as an OSS project.