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

Added UpdateHook method to RepositoryService. #71

Merged
merged 1 commit into from
Aug 21, 2020

Conversation

chhsia0
Copy link
Contributor

@chhsia0 chhsia0 commented Aug 21, 2020

The new UpdateHook method in RepositoryService would update an existing
SCM webhook and overwrite the list of events to watch.

In this patch, UpdateHook is not supported in the GitLab driver. It is
implemented separately in a followup patch.

@chhsia0
Copy link
Contributor Author

chhsia0 commented Aug 21, 2020

@bradrydzewski if the changes to the contents of Hook.Events in the GitLab driver breaks Drone, I could instead introduce a new Hook.NativeEvents field to have the actual names of the event options in GitLab.

@bradrydzewski
Copy link
Member

can you provide some more details regarding the breaking change?

@bradrydzewski
Copy link
Member

bradrydzewski commented Aug 21, 2020

I would also ask that we split this pull request into smaller chunks. For example, there is some refactoring or changes that may not be required to implement UpdateHook. Also in some cases we don't have full test coverage of things being refactored which makes me nervous that I might merge changes that cause a regression.

@bradrydzewski
Copy link
Member

bradrydzewski commented Aug 21, 2020

thanks for the explanations. My recommendation would be to submit the PR without GitLab support (make it a no-op, using an ErrNotImplemented) and then we handle GitLab support in a separate pull request. I think everything else is straight-for and can be merged right away, however, GitLab will take some time and would benefit from being reviewed separately (especially since it could have breaking impacts). Does that sound ok?

The new `UpdateHook` method in `RepositoryService` would update an existing
SCM webhook and overwrite the list of events to watch.

In this patch, `UpdateHook` is not supported in the GitLab driver. It is
implemented separately in a followup patch.
@bradrydzewski
Copy link
Member

awesome, thanks so much!

@bradrydzewski bradrydzewski merged commit 3a23b6b into drone:master Aug 21, 2020
jstrachan pushed a commit to jstrachan/go-scm that referenced this pull request Dec 22, 2020
fix: Add tests and fix for the GitLab client.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants