You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Apologies if I use bad terminology here; I'm confused.
I am using a tool (atlantis) which tries to clone a PR and do some local work. This usually works, but fails to clone PRs that were created using the Agit workflow.
I created a PR as follows:
% git push origin HEAD:refs/for/main -o topic="agit-test" -o title="Test agit workflow"
Enumerating objects: 5, done.
Counting objects: 100% (5/5), done.
Delta compression using up to 64 threads
Compressing objects: 100% (3/3), done.
Writing objects: 100% (3/3), 530 bytes | 530.00 KiB/s, done.
Total 3 (delta 2), reused 0 (delta 0), pack-reused 0 (from 0)
remote:
remote: Create a new pull request for 'infinoid/agit-test':
remote: https://gitea.server/tf/repo/pulls/8
remote:
remote: . Processing 1 references
remote: Processed 1 references in total
To https://gitea.server/tf/repo
* [new reference] HEAD -> refs/pull/8/head
The tool got a webhook notification, saw the new PR and tried to clone it. That failed:
running git clone --depth=1 --branch refs/pull/8/head --single-branch https://atlantis:<redacted>@gitea.server/tf/repo.git /atlantis-data/repos/tf/repo/8/default
Cloning into '/atlantis-data/repos/tf/repo/8/default'...
warning: Could not find remote branch refs/pull/8/head to clone.
fatal: Remote branch refs/pull/8/head not found in upstream origin
: exit status 128
What is the right git clone command to clone an Agit PR? The above command didn't work, and the AGit documentation doesn't have any specific details about cloning.
Apparently the PR head ref is not visible to clients. Is this expected? The Agit workflow seems quite magical, so I don't really understand it. My best guess is that the staging branch was created under a fork with a different owner (infinoid/, not tf/), but it's not outwardly visible, or if it is, the webhook doesn't point at the right location, or the tool misunderstood the webhook data somehow.
The gist link has container logs, and the json webhook content that was sent to the tool.
Description
Apologies if I use bad terminology here; I'm confused.
I am using a tool (atlantis) which tries to clone a PR and do some local work. This usually works, but fails to clone PRs that were created using the Agit workflow.
I created a PR as follows:
The tool got a webhook notification, saw the new PR and tried to clone it. That failed:
What is the right
git clone
command to clone an Agit PR? The above command didn't work, and the AGit documentation doesn't have any specific details about cloning.Apparently the PR head ref is not visible to clients. Is this expected? The Agit workflow seems quite magical, so I don't really understand it. My best guess is that the staging branch was created under a fork with a different owner (
infinoid/
, nottf/
), but it's not outwardly visible, or if it is, the webhook doesn't point at the right location, or the tool misunderstood the webhook data somehow.The gist link has container logs, and the json webhook content that was sent to the tool.
Thanks!
Gitea Version
1.22.4
Can you reproduce the bug on the Gitea demo site?
No
Log Gist
https://gist.github.com/Infinoid/2c81d377645ef39a7b878804c315e621
Screenshots
No response
Git Version
No response
Operating System
Linux
How are you running Gitea?
self-hosted container
Database
PostgreSQL
The text was updated successfully, but these errors were encountered: