-
-
Notifications
You must be signed in to change notification settings - Fork 6
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
refactor into modules #53
base: master
Are you sure you want to change the base?
Conversation
return s | ||
|
||
|
||
invite_message = _fix_markdown( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could as well just have a Jinja template instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That is a good point! I would like to add that in as well.
|
||
from .db import PersistentStringSet | ||
from .gh import GithubApp | ||
from .events import github_app |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's not "events", it's
from .events import github_app | |
from .event_handlers import github_app |
conceptionally.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suppose we might want the name to include "github" too, since we might have other kinds of events later?
I also guess we might eventually want to refactor along the lines of logically-related-features, like "inviting new users", "dependency bumping", etc., instead of lower-level functional categories like "reacting to github events", "text strings", etc.
But no need to make the perfect the enemy of the good... I'm happy with merging this now and then worrying about that stuff later. @wgwz, what do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fair enough
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like both of the suggestions! I definitely prefer taking it one step further and splitting up the modules into logically related features. I'm willing to do that for this MR.
Co-Authored-By: Sviatoslav Sydorenko <wk@sydorenko.org.ua>
reading through the code i saw some opportunities to refactor. let me know what you think. the main idea is that i wanted to separate the quart app setup/controllers, from the github event handling code. i feel that it's a bit easier to read when it's split up this way. i got carried away and also decided it might be helpful to create a module that contains just messages that will get sent to users.