From 6c14bf39dccb1447cc826e716eced6cc1ee975fb Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 3 Aug 2021 10:29:55 +0900 Subject: [PATCH] build(deps): bump pylint from 2.8.3 to 2.9.6 (#6369) * build(deps): bump pylint from 2.8.3 to 2.9.6 Bumps [pylint](https://github.com/PyCQA/pylint) from 2.8.3 to 2.9.6. - [Release notes](https://github.com/PyCQA/pylint/releases) - [Changelog](https://github.com/PyCQA/pylint/blob/main/ChangeLog) - [Commits](https://github.com/PyCQA/pylint/compare/v2.8.3...v2.9.6) --- updated-dependencies: - dependency-name: pylint dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * pylint: fix 2.9.6 issues Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Peter Rowlands --- dvc/fs/dvc.py | 6 +++--- dvc/fs/git.py | 4 ++-- dvc/fs/repo.py | 6 +++--- dvc/fs/ssh.py | 2 +- test_requirements.txt | 2 +- tests/unit/utils/test_http.py | 4 ++-- 6 files changed, 12 insertions(+), 12 deletions(-) diff --git a/dvc/fs/dvc.py b/dvc/fs/dvc.py index d6e2392b1..612b40163 100644 --- a/dvc/fs/dvc.py +++ b/dvc/fs/dvc.py @@ -99,14 +99,14 @@ class DvcFileSystem(BaseFileSystem): # pylint:disable=abstract-method cache_path = out.cache_path return open(cache_path, mode=mode, encoding=encoding) - def exists(self, path): # pylint: disable=arguments-differ + def exists(self, path): # pylint: disable=arguments-renamed try: self.metadata(path) return True except FileNotFoundError: return False - def isdir(self, path): # pylint: disable=arguments-differ + def isdir(self, path): # pylint: disable=arguments-renamed try: meta = self.metadata(path) return meta.isdir @@ -129,7 +129,7 @@ class DvcFileSystem(BaseFileSystem): # pylint:disable=abstract-method except FileNotFoundError: return True - def isfile(self, path): # pylint: disable=arguments-differ + def isfile(self, path): # pylint: disable=arguments-renamed try: meta = self.metadata(path) return meta.isfile diff --git a/dvc/fs/git.py b/dvc/fs/git.py index 05acdbb90..b55d16489 100644 --- a/dvc/fs/git.py +++ b/dvc/fs/git.py @@ -36,8 +36,8 @@ class GitFileSystem(BaseFileSystem): # pylint:disable=abstract-method return tuple(relparts) def open( - self, path, mode="r", encoding=None - ): # pylint: disable=arguments-differ + self, path, mode="r", encoding=None, **kwargs + ): # pylint: disable=arguments-renamed # NOTE: this is incorrect, we need to use locale to determine default # encoding. encoding = encoding or "utf-8" diff --git a/dvc/fs/repo.py b/dvc/fs/repo.py index 5cab12b70..37e75ec09 100644 --- a/dvc/fs/repo.py +++ b/dvc/fs/repo.py @@ -136,7 +136,7 @@ class RepoFileSystem(BaseFileSystem): # pylint:disable=abstract-method def open( self, path, mode="r", encoding="utf-8", **kwargs - ): # pylint: disable=arguments-differ + ): # pylint: disable=arguments-renamed if "b" in mode: encoding = None @@ -173,7 +173,7 @@ class RepoFileSystem(BaseFileSystem): # pylint:disable=abstract-method return True - def isdir(self, path): # pylint: disable=arguments-differ + def isdir(self, path): # pylint: disable=arguments-renamed fs, dvc_fs = self._get_fs_pair(path) if dvc_fs and dvc_fs.repo.dvcignore.is_ignored_dir(path): @@ -204,7 +204,7 @@ class RepoFileSystem(BaseFileSystem): # pylint:disable=abstract-method _, dvc_fs = self._get_fs_pair(path) return dvc_fs is not None and dvc_fs.isdvc(path, **kwargs) - def isfile(self, path): # pylint: disable=arguments-differ + def isfile(self, path): # pylint: disable=arguments-renamed fs, dvc_fs = self._get_fs_pair(path) if dvc_fs and dvc_fs.repo.dvcignore.is_ignored_file(path): diff --git a/dvc/fs/ssh.py b/dvc/fs/ssh.py index 799e11d77..491c06ad8 100644 --- a/dvc/fs/ssh.py +++ b/dvc/fs/ssh.py @@ -4,7 +4,7 @@ import threading from funcy import cached_property, first, memoize, silent, wrap_prop, wrap_with -import dvc.prompt as prompt +from dvc import prompt from dvc.scheme import Schemes from dvc.utils.fs import as_atomic diff --git a/test_requirements.txt b/test_requirements.txt index 27af53497..a887f5700 100644 --- a/test_requirements.txt +++ b/test_requirements.txt @@ -31,7 +31,7 @@ pydocstyle==6.1.1 jaraco.windows==5.5.0 # pylint requirements -pylint==2.8.3 +pylint==2.9.6 # we use this to suppress pytest-related false positives in our tests. pylint-pytest==1.0.3 # we use this to suppress some messages in tests, eg: foo/bar naming, diff --git a/tests/unit/utils/test_http.py b/tests/unit/utils/test_http.py index 2051bcbaf..2a4de2078 100644 --- a/tests/unit/utils/test_http.py +++ b/tests/unit/utils/test_http.py @@ -49,8 +49,8 @@ def test_open_url_peek_rb(tmp_path, monkeypatch, http): with open_url((http / "sample.txt").url, mode="rb") as fd: text = text.encode("utf8") - assert fd.peek(len(text)) == text + assert fd.peek(len(text)) == text # pylint: disable=no-member assert read_nbytes(fd, len(text), mode="rb") == text - assert fd.peek(len(text)) == text + assert fd.peek(len(text)) == text # pylint: disable=no-member assert fd.read() == text assert fd.read() == b""