jenkins-bot has submitted this change. ( 
https://gerrit.wikimedia.org/r/c/pywikibot/core/+/834642 )

Change subject: [flake8] Solve B026 bugbear issue
......................................................................

[flake8] Solve B026 bugbear issue

Do not unpack positional arguments after keyword arguments

Bug: T318472
Change-Id: I58c75370f5d69a63fcfb08b5659c870e7db8d504
---
M pywikibot/page/_wikibase.py
M tox.ini
2 files changed, 5 insertions(+), 9 deletions(-)

Approvals:
  Legoktm: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/pywikibot/page/_wikibase.py b/pywikibot/page/_wikibase.py
index 4193764..8a721d7 100644
--- a/pywikibot/page/_wikibase.py
+++ b/pywikibot/page/_wikibase.py
@@ -1264,15 +1264,11 @@
         data['datatype'] = self._type
         return data

-    def newClaim(self, *args, **kwargs):
-        """
-        Helper function to create a new claim object for this property.
-
-        :rtype: pywikibot.page.Claim
-        """
+    def newClaim(self, *args, **kwargs) -> 'Claim':
+        """Helper function to create a new claim object for this property."""
         # todo: raise when self.id is -1
-        return Claim(self.site, self.getID(), datatype=self.type,
-                     *args, **kwargs)
+        return Claim(self.site, self.getID(), *args, datatype=self.type,
+                     **kwargs)

     def getID(self, numeric: bool = False):
         """
diff --git a/tox.ini b/tox.ini
index be649f4..6a83292 100644
--- a/tox.ini
+++ b/tox.ini
@@ -110,7 +110,7 @@

 # DARXXX: Darglint docstring issues to be solved

-ignore = 
B007,B026,C103,D105,D211,D401,D413,D412,DAR003,DAR101,DAR102,DAR201,DAR202,DAR301,DAR401,DAR402,DAR501,H101,H238,H301,H306,H404,H405,H903,P101,P102,P103,P205,W503
+ignore = 
B007,C103,D105,D211,D401,D413,D412,DAR003,DAR101,DAR102,DAR201,DAR202,DAR301,DAR401,DAR402,DAR501,H101,H238,H301,H306,H404,H405,H903,P101,P102,P103,P205,W503
 enable-extensions = H203,H204,H205,N818

 color = always

--
To view, visit https://gerrit.wikimedia.org/r/c/pywikibot/core/+/834642
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.wikimedia.org/r/settings

Gerrit-Project: pywikibot/core
Gerrit-Branch: master
Gerrit-Change-Id: I58c75370f5d69a63fcfb08b5659c870e7db8d504
Gerrit-Change-Number: 834642
Gerrit-PatchSet: 2
Gerrit-Owner: Xqt <[email protected]>
Gerrit-Reviewer: Legoktm <[email protected]>
Gerrit-Reviewer: Matěj Suchánek <[email protected]>
Gerrit-Reviewer: jenkins-bot
Gerrit-MessageType: merged
_______________________________________________
Pywikibot-commits mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to