Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gitlab server should handle the draft status #1160

Closed
paolomainardi opened this issue Aug 20, 2024 · 6 comments · Fixed by #1165 or #1177
Closed

Gitlab server should handle the draft status #1160

paolomainardi opened this issue Aug 20, 2024 · 6 comments · Fixed by #1165 or #1177

Comments

@paolomainardi
Copy link
Contributor

paolomainardi commented Aug 20, 2024

This is an enhancement propsal.

I think that would be useful if the gitlab webhook server could be capable to discard MR in draft status, of course this should be a configurable behavior.

If you think this is useful, I can try to implement it.

@mrT23
Copy link
Collaborator

mrT23 commented Aug 21, 2024

first share more details.
exactly what is not working today, in which platform, in which state.

@paolomainardi
Copy link
Contributor Author

I never said that something is not working today. It is a proposal to handle the "draft" status.

@mrT23
Copy link
Collaborator

mrT23 commented Aug 21, 2024

i approved the PR.

Notice that this is not "gitlab webhook server", and that's what led to my pondering.
It's a Gitlab pipeline.

@paolomainardi
Copy link
Contributor Author

@mrT23, thanks, but the pull request was unrelated to this issue; I just faced that bug today while trying to integrate it into a gitlab pipeline.

To add some useful info here, at the moment, AFAIK, the Gitlab Server handles two statuses: open, reopen - ref: https://github.com/Codium-ai/pr-agent/blob/main/pr_agent/servers/gitlab_webhook.py#L127

I was suggesting that draft merge requests could be excluded from merge request parsing using a configuration toggle.

It should be easy to implement and offer several advantages. On the one hand, it reduces the traffic to the selected AI vendor for unwanted parsing, and on the other hand, it respects the draft semantics.

@mrT23
Copy link
Collaborator

mrT23 commented Aug 21, 2024

welcome to open a PR also for this

paolomainardi added a commit to paolomainardi/pr-agent that referenced this issue Aug 22, 2024
@mrT23 mrT23 closed this as completed in ffaf5d5 Aug 23, 2024
@paolomainardi
Copy link
Contributor Author

Thanks @mrT23

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants