From 6c8913c0f17a4a670ac44a83679071c90881550b Mon Sep 17 00:00:00 2001 From: Ivan Niedielnitsev Date: Wed, 30 Nov 2022 11:45:08 +0200 Subject: [PATCH] style: [EDXOLDMNG-200] added pylint disable to fix CI --- credentials/apps/api/v2/serializers.py | 4 ++-- credentials/apps/credentials/tests/factories.py | 5 ++++- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/credentials/apps/api/v2/serializers.py b/credentials/apps/api/v2/serializers.py index b7c5a89245..a16bac33a8 100644 --- a/credentials/apps/api/v2/serializers.py +++ b/credentials/apps/api/v2/serializers.py @@ -371,8 +371,8 @@ def save_related_signatories(self, certificate: CourseCertificate): """ Generates new signatures and relates them to the certificate. """ - raw_signatories_data = self.context["request"].data.get("signatories") - files = self.context["request"].FILES + raw_signatories_data = self.context["request"].data.get("signatories") # pylint: disable=no-member + files = self.context["request"].FILES # pylint: disable=no-member if raw_signatories_data and files: signatories_parsed_data = self.parse_signatories_in_files(raw_signatories_data, files) diff --git a/credentials/apps/credentials/tests/factories.py b/credentials/apps/credentials/tests/factories.py index 1ceb3e1e02..2d83c00a49 100644 --- a/credentials/apps/credentials/tests/factories.py +++ b/credentials/apps/credentials/tests/factories.py @@ -13,7 +13,10 @@ def create_test_image(extension): - return ContentFile(ImageField()._make_data({"width": 1289, "height": 720}), f"example.{extension}") + return ContentFile( + ImageField()._make_data({"width": 1289, "height": 720}), # pylint: disable=protected-access + f"example.{extension}" + ) class AbstractCertificateFactory(factory.django.DjangoModelFactory):