From 86e7598f037da4d097efddfd0c0926c81ef10dea Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Sun, 29 Mar 2026 10:24:47 +0000 Subject: [PATCH] Address code review: fix E501 consistency in AGENTS.md, fix exception handling in test_security.py Agent-Logs-Url: https://github.com/christianlouis/dmarq/sessions/9d256101-34b6-4861-a8cf-7f86f32b54d5 Co-authored-by: christianlouis <361235+christianlouis@users.noreply.github.com> --- AGENTS.md | 2 +- backend/app/tests/test_security.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/AGENTS.md b/AGENTS.md index 7616167..da3b1bc 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -105,7 +105,7 @@ black --check backend/app isort --check-only backend/app # Flake8 lint -flake8 backend/app --max-line-length=100 --extend-ignore=E203,W503 +flake8 backend/app --max-line-length=100 --extend-ignore=E203,W503,E501 ``` If Black or isort report issues, fix them automatically: diff --git a/backend/app/tests/test_security.py b/backend/app/tests/test_security.py index 395d0d6..466a136 100644 --- a/backend/app/tests/test_security.py +++ b/backend/app/tests/test_security.py @@ -149,5 +149,5 @@ class TestXMLParsingSecurity: result = DMARCParser.parse_file(xxe_payload, "test.xml") org_name = result.get("org_name", "") assert "root:" not in org_name and "/bin" not in org_name - except (ValueError, Exception): + except Exception: pass # Expected – defusedxml blocks DTD processing