Skip to content

Commit

Permalink
Remove unused parsedmarc.utils.tempdir (#517)
Browse files Browse the repository at this point in the history
Parsedmarc.utils was creating a temp directory on every import, but this directory is no longer used anywhere.
  • Loading branch information
0xabu authored May 22, 2024
1 parent c150c76 commit ed92e0f
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions parsedmarc/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
import json
import hashlib
import base64
import atexit
import mailbox
import re
import csv
Expand Down Expand Up @@ -45,16 +44,6 @@
mailparser_logger = logging.getLogger("mailparser")
mailparser_logger.setLevel(logging.CRITICAL)

tempdir = tempfile.mkdtemp()


def _cleanup():
"""Remove temporary files"""
shutil.rmtree(tempdir)


atexit.register(_cleanup)


class EmailParserError(RuntimeError):
"""Raised when an error parsing the email occurs"""
Expand Down

0 comments on commit ed92e0f

Please sign in to comment.