Tag not triggering builds after years of working

Hey.

We have created builds for our repository with the same .travis.yml config for years and yesterday Github Releases stopped triggering builds.

A little bit of digging lead me to following:

  • When a Release is created in Github, Travis receives a push request with the name of the branch that was tagged (master) not with the name of the tag (vX.X.X).
  • Previously a Release created a push event request with the name of the Tag (vX.X.X) which triggered a build.

In our case “master” is not in the allow list but we declare a regex for allowing tags.
What has changed and what is the recommended course of action??
There is no documentation or changelog present that suggests a necessary update to our .travis.yml config.

example from .travis.yml

branches:
  only:
    - ...
    - /^v\d+\.\d+(\.\d+)$/

deploy:
  - provider: ...
    ...
    on:
      repo: ...
      tags: true
1 Like

Hi @ackoppel,

Can you give me the build link so I can take a look at this?

@Montana we’re having a similar issue. The TRAVIS_TAG env var seems to not be getting set for releases being created within the Github release UI, and the TRAVIS_BRANCH env var is set to master instead of the release tag. Here’s an example build: Travis CI - Test and Deploy with Confidence

For now, we’ve been manually creating releases using git tag -s <new_tag> - it seems like git tag -a <new_tag> has the same problem as the Github release UI.

Hi @jsadwith,

This should work now.

1 Like

Confirming it’s working. Thanks @Montana !

Ah, great to know @jsadwith!

1 Like