diff options
author | Bernát Gábor <bgabor8@bloomberg.net> | 2023-02-05 13:03:52 -0800 |
---|---|---|
committer | Bernát Gábor <bgabor8@bloomberg.net> | 2023-02-05 13:03:52 -0800 |
commit | 507c26286ec815976db8f695394eefd03882f96e (patch) | |
tree | 2c69e7ed3179b53a635e6a700d3963639670116c | |
parent | a98c3f519f447de28a899f5e3f7bec5c754d6183 (diff) | |
download | virtualenv-all-repos_autofix_bump-2023-02-05.tar.gz |
Bump deps and toolsall-repos_autofix_bump-2023-02-05
Committed via https://github.com/asottile/all-repos
-rw-r--r-- | .pre-commit-config.yaml | 24 | ||||
-rw-r--r-- | pyproject.toml | 16 | ||||
-rw-r--r-- | src/virtualenv/config/cli/parser.py | 1 | ||||
-rw-r--r-- | src/virtualenv/create/via_global_ref/_virtualenv.py | 7 | ||||
-rw-r--r-- | src/virtualenv/create/via_global_ref/builtin/python2/site.py | 3 | ||||
-rw-r--r-- | src/virtualenv/discovery/py_info.py | 3 | ||||
-rw-r--r-- | tasks/__main__zipapp.py | 6 | ||||
-rw-r--r-- | tox.ini | 14 |
8 files changed, 35 insertions, 39 deletions
diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 90440e6..e0a6ad8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -17,36 +17,36 @@ repos: - id: add-trailing-comma args: [--py36-plus] - repo: https://github.com/asottile/pyupgrade - rev: v3.2.1 + rev: v3.3.1 hooks: - id: pyupgrade args: ["--py37-plus"] exclude: "^(src/virtualenv/create/via_global_ref/_virtualenv.py|src/virtualenv/create/via_global_ref/builtin/python2/site.py|src/virtualenv/discovery/py_info.py|tasks/__main__zipapp.py)$" - repo: https://github.com/asottile/pyupgrade - rev: v2.38.4 + rev: v3.3.1 hooks: - id: pyupgrade files: "^(src/virtualenv/create/via_global_ref/_virtualenv.py|src/virtualenv/create/via_global_ref/builtin/python2/site.py|src/virtualenv/discovery/py_info.py|tasks/__main__zipapp.py)$" - repo: https://github.com/PyCQA/isort - rev: 5.11.4 + rev: 5.12.0 hooks: - id: isort - repo: https://github.com/psf/black - rev: 22.12.0 + rev: 23.1.0 hooks: - id: black args: [--safe] - repo: https://github.com/asottile/blacken-docs - rev: v1.12.1 + rev: 1.13.0 hooks: - id: blacken-docs - additional_dependencies: [black==22.12] + additional_dependencies: [black==23.1] - repo: https://github.com/pre-commit/pygrep-hooks - rev: v1.9.0 + rev: v1.10.0 hooks: - id: rst-backticks - repo: https://github.com/tox-dev/tox-ini-fmt - rev: "0.5.2" + rev: "0.6.1" hooks: - id: tox-ini-fmt args: ["-p", "fix"] @@ -55,11 +55,11 @@ repos: hooks: - id: flake8 additional_dependencies: - - flake8-bugbear==22.12.6 + - flake8-bugbear==23.1.20 - flake8-comprehensions==3.10.1 - flake8-pytest-style==1.6 - flake8-spellcheck==0.28 - - flake8-unused-arguments==0.0.12 + - flake8-unused-arguments==0.0.13 - flake8-noqa==1.3 - pep8-naming==0.13.3 - flake8-pyproject==1.2.2 @@ -68,11 +68,11 @@ repos: hooks: - id: prettier additional_dependencies: - - prettier@3.0.0-alpha.4 + - prettier@2.7.1 - "@prettier/plugin-xml@2.2" args: ["--print-width=120", "--prose-wrap=always"] - repo: https://github.com/igorshubovych/markdownlint-cli - rev: v0.32.2 + rev: v0.33.0 hooks: - id: markdownlint - repo: meta diff --git a/pyproject.toml b/pyproject.toml index f14b417..03c42d4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [build-system] build-backend = "hatchling.build" -requires = ["hatch-vcs>=0.3", "hatchling>=1.11.1"] +requires = ["hatch-vcs>=0.3", "hatchling>=1.12.2"] [project] name = "virtualenv" @@ -16,17 +16,17 @@ scripts.virtualenv = "virtualenv.__main__:run_with_catch" requires-python = ">=3.7" dependencies = [ "distlib<1,>=0.3.6", - "filelock<4,>=3.4.1", - 'importlib-metadata>=4.8.3; python_version < "3.8"', - "platformdirs<3,>=2.4", + "filelock<4,>=3.9", + 'importlib-metadata>=6; python_version < "3.8"', + "platformdirs<3,>=2.6.2", ] optional-dependencies.test = [ "covdefaults>=2.2.2", - "coverage>=7.0.2", + "coverage>=7.1", "coverage-enable-subprocess>=1", "flaky>=3.7", - "packaging>=22", - "pytest>=7.2", + "packaging>=23", + "pytest>=7.2.1", "pytest-env>=0.8.1", "pytest-freezegun>=0.4.2", "pytest-mock>=3.10", @@ -35,7 +35,7 @@ optional-dependencies.test = [ ] optional-dependencies.docs = [ "proselint>=0.13", - "sphinx>=5.3", + "sphinx>=6.1.3", "sphinx-argparse>=0.4", "sphinx-rtd-theme>=1.1.1", "towncrier>=22.12", diff --git a/src/virtualenv/config/cli/parser.py b/src/virtualenv/config/cli/parser.py index 5ab4fbd..f68e56e 100644 --- a/src/virtualenv/config/cli/parser.py +++ b/src/virtualenv/config/cli/parser.py @@ -110,7 +110,6 @@ class HelpFormatter(ArgumentDefaultsHelpFormatter): super().__init__(prog, max_help_position=32, width=240) def _get_help_string(self, action): - text = super()._get_help_string(action) if hasattr(action, "default_source"): default = " (default: %(default)s)" diff --git a/src/virtualenv/create/via_global_ref/_virtualenv.py b/src/virtualenv/create/via_global_ref/_virtualenv.py index faee64c..e030b4f 100644 --- a/src/virtualenv/create/via_global_ref/_virtualenv.py +++ b/src/virtualenv/create/via_global_ref/_virtualenv.py @@ -1,5 +1,4 @@ """Patches that are applied at runtime to the virtual environment""" -# -*- coding: utf-8 -*- import os import sys @@ -103,7 +102,7 @@ else: from imp import find_module from pkgutil import ImpImporter, ImpLoader - class _VirtualenvImporter(object, ImpImporter): + class _VirtualenvImporter(ImpImporter): def __init__(self, path=None): object.__init__(self) ImpImporter.__init__(self, path) @@ -116,13 +115,13 @@ else: pass return None - class _VirtualenvLoader(object, ImpLoader): + class _VirtualenvLoader(ImpLoader): def __init__(self, fullname, file, filename, etc): object.__init__(self) ImpLoader.__init__(self, fullname, file, filename, etc) def load_module(self, fullname): - module = super(_VirtualenvLoader, self).load_module(fullname) + module = super().load_module(fullname) patch_dist(module) module.__loader__ = None # distlib fallback return module diff --git a/src/virtualenv/create/via_global_ref/builtin/python2/site.py b/src/virtualenv/create/via_global_ref/builtin/python2/site.py index 4decd87..ac06345 100644 --- a/src/virtualenv/create/via_global_ref/builtin/python2/site.py +++ b/src/virtualenv/create/via_global_ref/builtin/python2/site.py @@ -1,4 +1,3 @@ -# -*- coding: utf-8 -*- """ A simple shim module to fix up things on Python 2 only. @@ -141,7 +140,7 @@ def disable_user_site_package(): # sys.flags is a c-extension type, so we cannot monkeypatch it, replace it with a python class to flip it sys.original_flags = sys.flags - class Flags(object): + class Flags: def __init__(self): self.__dict__ = {key: getattr(sys.flags, key) for key in dir(sys.flags) if not key.startswith("_")} diff --git a/src/virtualenv/discovery/py_info.py b/src/virtualenv/discovery/py_info.py index 2a39e50..98bf29b 100644 --- a/src/virtualenv/discovery/py_info.py +++ b/src/virtualenv/discovery/py_info.py @@ -3,7 +3,6 @@ The PythonInfo contains information about a concrete instance of a Python interp Note: this file is also used to query target interpreters, so can only use standard library methods """ -from __future__ import absolute_import, print_function import json import logging @@ -27,7 +26,7 @@ EXTENSIONS = _get_path_extensions() _CONF_VAR_RE = re.compile(r"\{\w+\}") -class PythonInfo(object): +class PythonInfo: """Contains information for a Python interpreter""" def __init__(self): diff --git a/tasks/__main__zipapp.py b/tasks/__main__zipapp.py index 87d4589..fdf1869 100644 --- a/tasks/__main__zipapp.py +++ b/tasks/__main__zipapp.py @@ -7,7 +7,7 @@ ABS_HERE = os.path.abspath(os.path.dirname(__file__)) NEW_IMPORT_SYSTEM = sys.version_info[0] == 3 -class VersionPlatformSelect(object): +class VersionPlatformSelect: def __init__(self): self.archive = ABS_HERE self._zip_file = zipfile.ZipFile(ABS_HERE, "r") @@ -67,13 +67,13 @@ class VersionPlatformSelect(object): if "distlib" not in self.modules: return - class DistlibFinder(object): + class DistlibFinder: def __init__(self, path, loader): self.path = path self.loader = loader def find(self, name): - class Resource(object): + class Resource: def __init__(self, content): self.bytes = content @@ -41,7 +41,7 @@ wheel_build_env = .pkg description = format the code base to adhere to our styles, and complain about what we cannot do automatically skip_install = true deps = - pre-commit>=2.21 + pre-commit>=3.0.4 commands = pre-commit run --all-files --show-diff-on-failure @@ -51,8 +51,8 @@ description = [run locally after tests]: combine coverage data and create report skip_install = true deps = covdefaults>=2.2.2 - coverage[toml]>=7.0.1 - diff_cover>=7.3 + coverage[toml]>=7.1 + diff_cover>=7.4 extras = parallel_show_output = true commands = @@ -77,7 +77,7 @@ set_env = description = check that the long description is valid (need for PyPI) skip_install = true deps = - build>=0.9 + build>=0.10 twine>=4.0.2 extras = commands = @@ -97,7 +97,7 @@ commands = description = upgrade pip/wheels/setuptools to latest skip_install = true deps = - black>=22.12 + black>=23.1 commands = python upgrade_wheels.py change_dir = {toxinidir}/tasks @@ -108,7 +108,7 @@ pass_env = description = do a release, required posarg of the version number deps = gitpython>=3.1.30 - packaging>=22 + packaging>=23 towncrier>=22.12 commands = python release.py --version {posargs} @@ -128,6 +128,6 @@ package = editable description = generate a zipapp skip_install = true deps = - packaging>=22 + packaging>=23 commands = python tasks/make_zipapp.py |