Is the following possible using Python?

  1. Given a directory with 500 emails in it. These are all bounced emails.
  2. Have script open 1st email
  3. Python extracts the failed email address (from body of email, not header or addressing)
  4. Script appends found email address to separate file of bad addresses
  5. Script does 2 thru 4 to the rest of the emails, untl they've all been harvested

Result is a single file with all the bad addresses.

Yes.

It looks like the email pkg will do the parsing, but what module would be used to actually open the email from the directory itis sitting in?

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.