Comments (5)
Thanks for the input, @AeonJJohnson , this is a great idea. Perhaps the default should be to continue on an error due to a bad email address. Then we could add a flag like --stop-on-error
.
I'm not sure what exact exception is thrown in the situations you're describing. Would you be able to add a detailed list to this issue? I think that mailmerge should fail on catastrophic errors like a bad SMTP password, while it should log and continue on errors like "SMTP server doesn't like email address X
".
from mailmerge.
I would find it most useful if mailmerge didn't just log the failed attempts but (optionally) created an output file that contains the rows of the original input csv file which failed. Possibly adding an extra column that contains the error message.
That way I could easily check the failed email addresses, correct them and run mailmerge
again on the edited file. Alternatively, it could output the full input database with the error message column added and I would filter that myself before processing the failed items.
Maybe this behavior could be triggered by a flag --dump-failed
or something similar. The filename would be something like mailmerge_fails.csv
by default and could be changed via --faildb
.
from mailmerge.
WDYT about including a unique log message in #9 so that you could grep
the most recent log for failed messages?
from mailmerge.
So the workflow would be
grep "sending failed" mailmerge.log > failed.txt
- Open the database in a spreadsheet or editor
less failed.txt
- Go through database by fail-log; edit as appropriate and introduce an indicator column so I can filter the re-send worthy rows
- Save the parts of the database that I want to send after my edit
- run mailmerge on that.
I guess it would work but to my personal taste (i.e. lazy) it feels more convenient to directly dive into the output file and start checking/correcting my bad email addresses without having to navigate to them one by one based on the grep output or putting together some shell magic to re-run mailmerge on just those lines, again. That's why I like the idea of an indicator column I can quickly filter by for editing and export.
Of course, if you feel that shouldn't be handled inside mailmerge itself, that could be done by an external helper script, too...
from mailmerge.
You make a good point that this could get complicated. Now that I think about it, your suggestion of writing a CSV with failed rows makes sense. Perhaps this should simply be the default behavior. A user could always simply ignore the fail log.
from mailmerge.
Related Issues (20)
- Recipe for machine-readable messages
- FEATURE MISSING: personal attachments HOT 2
- Block list HOT 1
- Apple Mail with attachments issue (former title: UTF-8 support issue) HOT 11
- Move test dependecies to extras_require
- Debug flag
- mails limit per mail feature HOT 5
- Interactive mode
- Drop Python 2 Support HOT 5
- Change CI to GitHub Actions
- setup.py has "html5" but It has a new name "html5lib"
- Inline images not working in thunderbird? HOT 5
- Crashes on email adresses with illegal characters HOT 2
- Replace `setup.py` with `pyproject.toml`
- Support CSV files with semicolons as separators HOT 3
- Add support for 2FA OAuth authentication HOT 2
- New release on Pipy HOT 1
- No mailmerge_server.conf file in the repository HOT 2
- Load system default SSL cert
- Space at the end of the header row
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mailmerge.