Drone not running build on tag push (from Gitea)

When pushing a new tag to my Gitea server, it does not trigger a new build, while it does work for commits.

From what I can see in Gitea all works as it is supposed to, it sends a webrequest to drone for both pushes, but the request for a tag is met with an empty response:

Tag request body:

{
  "secret": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
  "sha": "7c43a4422dd9892f89eb7957bb535568a24c70f3",
  "ref": "3.0.0",
  "ref_type": "tag",
  "repository": {
    "id": 18,
    "owner": {
      "id": 4,
      "login": "Element-Networks",
      "full_name": "",
      "email": "",
      "avatar_url": "https://git.element-networks.nl/user/avatar/Element-Networks/-1",
      "language": "",
      "is_admin": false,
      "last_login": "1970-01-01T00:00:00Z",
      "created": "2019-05-29T19:48:16Z",
      "username": "Element-Networks"
    },
    "name": "ansible-role-acme_ssl",
    "full_name": "Element-Networks/ansible-role-acme_ssl",
    "description": "",
    "empty": false,
    "private": false,
    "fork": false,
    "template": false,
    "parent": null,
    "mirror": false,
    "size": 238,
    "html_url": "https://git.element-networks.nl/Element-Networks/ansible-role-acme_ssl",
    "ssh_url": "ssh://git@git.element-networks.nl:2222/Element-Networks/ansible-role-acme_ssl.git",
    "clone_url": "https://git.element-networks.nl/Element-Networks/ansible-role-acme_ssl.git",
    "original_url": "",
    "website": "",
    "stars_count": 0,
    "forks_count": 0,
    "watchers_count": 4,
    "open_issues_count": 0,
    "open_pr_counter": 0,
    "release_counter": 9,
    "default_branch": "master",
    "archived": false,
    "created_at": "2019-05-29T20:25:42Z",
    "updated_at": "2020-05-04T13:32:07Z",
    "permissions": {
      "admin": false,
      "push": false,
      "pull": false
    },
    "has_issues": true,
    "internal_tracker": {
      "enable_time_tracker": true,
      "allow_only_contributors_to_track_time": true,
      "enable_issue_dependencies": true
    },
    "has_wiki": true,
    "has_pull_requests": true,
    "ignore_whitespace_conflicts": false,
    "allow_merge_commits": true,
    "allow_rebase": true,
    "allow_rebase_explicit": true,
    "allow_squash_merge": true,
    "avatar_url": ""
  },
  "sender": {
    "id": 2,
    "login": "jeff",
    "full_name": "Jeffrey van Pelt",
    "email": "jeffrey.vanpelt@element-networks.nl",
    "avatar_url": "https://git.element-networks.nl/user/avatar/jeff/-1",
    "language": "en-US",
    "is_admin": true,
    "last_login": "2020-05-01T19:57:13Z",
    "created": "2019-05-29T13:10:00Z",
    "username": "jeff"
  }
}

I run the server in Docker and there are no logs of this transaction either whatsoever…

I also tried sending it with cURL, no success either:

$ curl -XPOST https://drone.element-networks.nl/hook?secret=xxxxxxxx --data "@/tmp/rahmu4Ae"
$

If you need it, I can also add the above details for a ‘regular’ commit, but as they are working just fine, I’d say it’s clutter :slight_smile:

Gitea sends two webhooks when you create a tag. It sends a push webhook and a tag webhook. Drone relies on the push webhook. There was a regression in Gitea and as a result it is no longer sending push webhooks when a tag is pushed https://github.com/go-gitea/gitea/pull/11082

We did receive a pull request to patch Drone accordingly, however, I am not convinced that this is not a Gitea regression since the previous behavior was consistent with GitHub and GitLab, and the new behavior is no longer consistent and is breaking for anyone that relies on this change.

Thanks for the reply!

I have reverted my gitea installation back to 1.11.5 and this fixed the issue again (I was running it against the ‘latest’ tag on docker hub).

The issue you linked seems to have a fix in it as well, but I’m not sure if it made it to the docker images just yet.

You can mark it as fixed :slight_smile:

So that means, the Gitea Release plugin will no longer work, as it is only available for tags?

No, there was a Gitea regression that was subsequently fixed / reverted by the Gitea maintainers here. Everything should work as expected as long as you are using a version of Gitea that does not contain the regression.

Oh really! Just restarted Gitea on its latest docker image and now the pipeline step runs. :+1: