Imported config results in out of order build stages despite order explicitly specified

I’m still seeing this problem, even with order defined in stages.

Context: I have a set of imported configs (part of https://github.com/dwhswenson/autorelease/) that I use to do very careful PyPI releases in my projects. The cycle goes like this:

PR to master: Stages: test
PR to stable: Stages: test -> deploy_testpypi -> test_testpypi
Merge to stable: Stages: test -> cut_release (new GitHub release)
New release (version tag): Stages: test -> deploy_pypi

There’s a main (user-facing) import at dwhswenson/autorelease:autorelease-travis.yml, which then imports each stage individually. When I do a PR to stable, the order is incorrect. It tries to do the test_testpypi before deploy_testpypi. (Note that by manually forcing the deploy_testpypi to run once, tests will pass. But this is not how it should work!)

Things I tried:

In all cases, the stages parameter shows up in the config JSON, with the correct ordering of deploy_testpypi and test_testpypi (in fact, the last version, with stages both imported and defined locally, lists the whole sequence twice). In all cases, the requested order is not used by Travis.

Note that this set of configs used to work fine. I assume this is the result of the same change the OP noticed (last time I did a release was before then).

1 Like

Looks like it was my error. In the explicit stage ordering, I used underscores, whereas apparently I had spaces in the actual stage names.

That said, there was no warning in the build config validation. May there could be a validation test that the stages a user lists actually exist?