sympy / sympy-bot

GitHub bot for SymPy
https://github.com/sympy-bot
Other
22 stars 11 forks source link

Auto-assign issues #73

Open asmeurer opened 4 years ago

asmeurer commented 4 years ago

Fixes #72

Still a work in progress but the basic concept works. See https://github.com/asmeurer/GitHub-Issues-Test/pull/43

asmeurer commented 4 years ago

This basically works the way I want it to. I just need to add tests and update the existing tests. But it would be good to get a concept review first to see if this is something we actually want to do.

asmeurer commented 4 years ago

OK, here's a snag. It looks like you can't actually assign people to an issue unless they are members of the organization. I know GitHub has had requests to change this, but it hasn't happened yet.

So we either need to sit on this until they do, or implement https://github.com/sympy/sympy-bot/issues/68 (give all PR authors Triage permissions). https://github.com/sympy/sympy-bot/issues/68 would have other advantages as well, and I think it wouldn't be too hard. One issue is that if a user is given Triage permissions, I don't know if you can assign them to issues right away or if they have to accept the invite first. If they have to accept the invite, then the bot wouldn't be able to assign them until some future PR event that occurs after they accept the invite (we could enable comment webhook updates if this is the case to get more pushes; we should still be fine for being under API limits I'd imagine).

asmeurer commented 4 years ago

I guess you can assign anyone who has commented on the issue. That should cover most of the use cases. We can post a comment asking people to comment on the issue about the pull request if they haven't commented on the issue.

asmeurer commented 4 years ago

GitHub now has a way to link issues without using "Fixes" but I don't see anything about it in the API.

asmeurer commented 4 years ago

Might wait to see if they add it. It would make the logic here a lot simpler.