mailbagit
mailbagit copied to clipboard
Controller refactoring
The problem the component solves
Currently, most of the mailbagit functionality is run step-by-step in the main controller, controller.py
. This works fine, but there might be a more optimized way to structure some of this code.
Relevant part of mailbag spec?
n/a
Type of component
- [x] Core
- [ ] Input
- [ ] Attachments
- [ ] Derivatives conversion
- [ ] Reporting/Exporting
- [ ] GUI
- [ ] Distribution
Expected contribution
- [x] Pull Request
- [x] Comment with proposed solution
Major challenges or things to keep in mind
Disambiguation between accounts and messages is needed. This will this clean up duplicate logic that could be moved to the controller.
I believe that this is also blocking us from addressing #151, as mail.attachments
objects can also return message objects. If much of the outside-of-message logic can be removed from .messages()
then that method could potentially be called to parse message objects in mail.attachments
.
attached_msg-151 makes a poor attempt at this.