Skip to content

Commit

Permalink
PyLint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
ivankravets committed Apr 28, 2020
1 parent d1b394b commit 5d8440f
Show file tree
Hide file tree
Showing 7 changed files with 6 additions and 8 deletions.
1 change: 1 addition & 0 deletions platformio/builder/tools/piolib.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@

# pylint: disable=no-member, no-self-use, unused-argument, too-many-lines
# pylint: disable=too-many-instance-attributes, too-many-public-methods
# pylint: disable=assignment-from-no-return

from __future__ import absolute_import

Expand Down
2 changes: 1 addition & 1 deletion platformio/commands/home/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
# See the License for the specific language governing permissions and
# limitations under the License.

# pylint: disable=keyword-arg-before-vararg, arguments-differ
# pylint: disable=keyword-arg-before-vararg,arguments-differ,signature-differs

import os
import socket
Expand Down
2 changes: 1 addition & 1 deletion platformio/exception.py
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ class PlatformIOPackageException(PlatformioException):
pass


class UnknownPackage(PlatformIOPackageException):
class UnknownPackage(UserSideException):

MESSAGE = "Detected unknown package '{0}'"

Expand Down
2 changes: 1 addition & 1 deletion platformio/managers/core.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
"tool-pvs-studio": "~7.7.0",
}

# pylint: disable=arguments-differ
# pylint: disable=arguments-differ,signature-differs


class CorePackageManager(PackageManager):
Expand Down
1 change: 1 addition & 0 deletions platformio/managers/lib.py
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ def _cmp_dates(datestr1, datestr2):
for v in versions:
semver_new = self.parse_semver_version(v["name"])
if semver_spec:
# pylint: disable=unsupported-membership-test
if not semver_new or semver_new not in semver_spec:
continue
if not item or self.parse_semver_version(item["name"]) < semver_new:
Expand Down
2 changes: 1 addition & 1 deletion platformio/managers/package.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def __iter__(self):
return self

def __next__(self):
return self.next()
return self.next() # pylint: disable=not-callable

@staticmethod
@util.memoized(expire="60s")
Expand Down
4 changes: 0 additions & 4 deletions platformio/telemetry.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,10 +294,6 @@ def on_exception(e):
isinstance(e, cls)
for cls in (IOError, exception.ReturnErrorCode, exception.UserSideException,)
]
try:
skip_conditions.append("[API] Account: " in str(e))
except UnicodeEncodeError as ue:
e = ue
if any(skip_conditions):
return
is_fatal = any(
Expand Down

0 comments on commit 5d8440f

Please sign in to comment.