Sync certain actions with mail source (e.g. move to archive folder)
I would like to use an instance of Mailpile running locally on my computer and still manage my mail with an app on my phone (e.g. K-9 mail on Android). At the moment, archiving a message on Mailpile does not remove it from the inbox on the server (either with IMAP or with an offlineimap-synced maildir) and move it to the archive folder. This entails that I need to move every mail that I would like to get out of my inbox twice, once in each app.
It would be very useful if Mailpile could be configured to move mails between source folders when it already knows which folders correspond to archive, spam, etc. For the beginning, syncing only the "archive" and "mark as spam" action with the mail source would already be very useful.
I am aware of the fact that, architecturally, Mailpile wants to use the mail source as a read-only data repository, so perhaps this is something that would be implemented by a plugin or by a third-party tool.
But I would still like to submit this as a feature request, as
- it seems very useful for those who do not plan to use one single instance of Mailpile as the only access point to their mails (it's not trivial to run it on a server, and some people might not want to keep all their mail and their private keys on a server)
- Mailpile seems already to collect all the data needed to implement the feature
- I would be willing to contribute towards a bounty for implementing that feature
I don't really see why mailpile is supposed to read only on the server. I wish it would work like android or ios imap mail app. I used mailpile search to gather things i wanted to delete then realized it made no effect on my actual gmail account.
Is it a security issue or something to sync changes with the server? I don't think many people nowadays only check email on 1 device.
It is not a design goal to treat mail sources as read only - that is merely developer caution. Getting that stuff right is tricky and we'd rather treat people's precious mail as read-only until we are confident that our code isn't going to freak out and delete everything. :-)
So this is absolutely on our list of things we would like to do, and has been a stretch goal for 1.0 - but realistically, this is hard enough to do that it will probably get bumped to 1.1 or 1.2. But it IS on our list.
I posted a small bounty to get started: https://www.bountysource.com/issues/4937936-sync-certain-actions-with-mail-source-e-g-move-to-archive-folder
The bounty for this is now at $210.
The bounty for this issue is now at ~$800
Tagging as Spam should also move to IMAP:Spam folder to also train mail server
probably it should be mentioned that mailpile 1.0 is currently not syncing with imap servers, but just reads the message once. Hence no changes on the mail-server will be reflected in mailpile nor changes in mailpile will be reflected on the mail-server hope I got that rigth....
What would be the best way to implment this? I see the following possibilities:
- Make a mailbox storage class that maps to an IMAP server.
- Extend the IMAP source to also have the mailbox interface.
- Refactor everything to make the storage and retrieval of mails be in the same kind of class.
What do you think?
@Leo2807, I know you mean well, but I do think you should research how the app works before making suggestions. Those things have already all, more or less, been done.
The issue is that the way Mailpile tags and actions should be mapped to IMAP folders is not obvious except in a few special cases. In general, this is tricky and confusing. Consider when the user has one set of tags, but four IMAP accounts. What then?
Figuring out what is the right thing to do needs focus and time, and we just haven't had that yet. Once we know what needs to be done, then we can start thinking about how to rejigger the code.
@BjarniRunar IMO the solution should be to have tags associated with an account and purely local tags (that of course don't sync).
PS: Just tried mailpile for the first time in a year and am very impressed by the progress you made! I also watched your SHA talk in which you state "mailpile is not a syncing IMAP client". Can you clarify what you mean by that? I mean what exactly are the goals on syncing. Is it planned to be able to sync read-state or actually delete mail from the server?
Current bounty is at 1 grand, that would be a nice chunk of funding for the project
Hi @Queuecumber! Yes and no? That's less than a week of work at U.S. market rate salaries. Devs in less expensive locales might be willing to work two weeks for that? Two weeks of work? I am not sure I could pull this off in two weeks, and nobody knows the code better than me, so... I'd love to see someone claim the bounty though, that would be really neat.
I'm a bit worried about this though; $1000 is a large enough amount of money that it starts to matter how the project is defined. What is the criteria for claiming the bounty? Who makes the call whether a PR is good enough? If I do all the prep work until what's left does fit in a week of work... does someone else get to claim the money? How does this make any sense? :question:
... also, a bunch of those pledges are now 4 years old. I am not sure people will be happy to see money disappear from their accounts based on a pledge they made so long ago. So either the money won't actually arrive, or it'll make people mad. I'm not super comfortable with this situation.
HI, this issue seems very old, I would like to work on this.