Skip to content

Commit

Permalink
Code style fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
seanthegeek committed Sep 4, 2024
1 parent e967778 commit 5973ca8
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 5 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/python-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ jobs:
make html
- name: Check code style
run: |
flake8 *.py parsedmarc/*.py
ruff check *.py parsedmarc/*.py
- name: Run unit tests
run: |
coverage run tests.py
Expand Down
8 changes: 5 additions & 3 deletions parsedmarc/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -587,11 +587,12 @@ def parse_aggregate_report_xml(

def extract_report(content):
"""
Extracts text from a zip or gzip file, as a base64-encoded string, file-like object,
or bytes.
Extracts text from a zip or gzip file, as a base64-encoded string,
file-like object, or bytes.
Args:
content: report file as a base64-encoded string, file-like object or bytes.
content: report file as a base64-encoded string, file-like object or
bytes.
Returns:
str: The extracted text
Expand Down Expand Up @@ -639,6 +640,7 @@ def extract_report(content):

return report


def extract_report_from_file_path(file_path):
"""Extracts report from a file at the given file_path"""
try:
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ mailsuite>=1.6.1
pygelf
nose>=1.3.7
wheel>=0.37.0
flake8>=3.7.8
ruff
jinja2>=2.10.1
packaging>=19.1
imagesize>=1.1.0
Expand Down

0 comments on commit 5973ca8

Please sign in to comment.