From 48a3a292a38a33dbf0cba8344f57ee5af9583911 Mon Sep 17 00:00:00 2001 From: Sebastian Wagner Date: Tue, 30 Jul 2024 10:05:28 +0200 Subject: [PATCH] remove print statement, add github check for it --- .github/workflows/print.yml | 19 +++++++++++++++++++ intelmq_certbund_contact/rulesupport.py | 1 - 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/print.yml diff --git a/.github/workflows/print.yml b/.github/workflows/print.yml new file mode 100644 index 0000000..f03250d --- /dev/null +++ b/.github/workflows/print.yml @@ -0,0 +1,19 @@ +name: Check for print statements + +on: + push: + pull_request: + +permissions: + contents: read + +jobs: + print: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + - name: Grep for print + run: | + ! grep -E 'print *\(' -r intelmq/ intelmq_certbund_contact/*.py diff --git a/intelmq_certbund_contact/rulesupport.py b/intelmq_certbund_contact/rulesupport.py index 9cef375..197ce54 100644 --- a/intelmq_certbund_contact/rulesupport.py +++ b/intelmq_certbund_contact/rulesupport.py @@ -336,7 +336,6 @@ def as_dict_for_event(self, event): aggregate_identifier = self.aggregate_key.copy() for field in self.aggregate_fields: aggregate_identifier[field] = event.get(field) - print('as_dict_for_event, aggregate_identifier', aggregate_identifier, ) return dict(medium=self.medium, recipient_address=self.recipient_address,