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

not unassigning itself if MR author #203

Closed
wants to merge 4 commits into from

Conversation

micheelengronne
Copy link

Marge-bot will not unassign/reassign itself if it is the author.

Trying to solve #189 and #202

@aschmolck
Copy link
Contributor

Looking at the code, it doesn't seem to me that this changes existing behavior, since the only place these functions should be called for is unassign_from_mr which looks as follows:

marge/job.py-    def unassign_from_mr(self, merge_request):
marge/job.py-        log.info('Unassigning from MR !%s', merge_request.iid)
marge/job.py-        author_id = merge_request.author_id
marge/job.py-        if author_id != self._user.id:
marge/job.py:            merge_request.assign_to(author_id)
marge/job.py-        else:
marge/job.py-            merge_request.unassign()

This also means I don't understand why the reassign spam is actually happening in the first place. Did I overlook something?

@micheelengronne
Copy link
Author

The current patch does not seem to work. I am investigating.

@micheelengronne
Copy link
Author

The problem is not assign/unassign but the fact that marge-bot does not check if a comment was already made for this build and this status. It should check that instead.

@micheelengronne
Copy link
Author

I will write another PR.

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.

2 participants