Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[pre-commit.ci] pre-commit autoupdate #1896

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
---
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
rev: v5.0.0
hooks:
- id: end-of-file-fixer
- id: trailing-whitespace
Expand All @@ -15,7 +15,7 @@ repos:
- id: check-yaml
files: .*\.(yaml|yml)$
- repo: https://github.com/codespell-project/codespell
rev: v2.3.0
rev: v2.4.0
hooks:
- id: codespell
name: codespell
Expand All @@ -28,7 +28,7 @@ repos:
additional_dependencies:
- tomli; python_version<'3.11'
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: "v0.6.3"
rev: "v0.9.3"
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
Expand All @@ -40,7 +40,7 @@ repos:
- id: yamllint
files: \.(yaml|yml)$
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.11.2
rev: v1.14.1
hooks:
- id: mypy
additional_dependencies:
Expand Down
2 changes: 1 addition & 1 deletion docs/jirashell.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Run it from the command line

In [1]:

This is a specialized Python interpreter (built on IPython) that lets you explore Jira as a service. Any legal
This is a specialized Python interpreter (built on IPython) that let's you explore Jira as a service. Any legal
Python code is acceptable input. The shell builds a ``JIRA`` client object for you (based on the launch parameters) and
stores it in the ``jira`` object.

Expand Down
8 changes: 4 additions & 4 deletions jira/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -1095,9 +1095,9 @@ def add_attachment(
if not fname and isinstance(attachment_io, BufferedReader):
fname = os.path.basename(attachment_io.name)

def generate_multipartencoded_request_args() -> (
tuple[MultipartEncoder, CaseInsensitiveDict]
):
def generate_multipartencoded_request_args() -> tuple[
MultipartEncoder, CaseInsensitiveDict
]:
"""Returns MultipartEncoder stream of attachment, and the header."""
attachment_io.seek(0)
encoded_data = MultipartEncoder(
Expand Down Expand Up @@ -4483,7 +4483,7 @@ def rename_user(self, old_user: str, new_user: str):
self._session.put(url, params=params, data=json.dumps(payload))
else:
raise NotImplementedError(
"Support for renaming users in Jira " "< 6.0.0 has been removed."
"Support for renaming users in Jira < 6.0.0 has been removed."
)

def delete_user(self, username: str) -> bool:
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ def get_unique_project_name():
run_number = os.environ["GITHUB_RUN_NUMBER"]
# please note that user underline (_) is not supported by
# Jira even if it is documented as supported.
return f"CI{hashify(f'{user}{run_number}',max_len=7)}"
return f"CI{hashify(f'{user}{run_number}', max_len=7)}"
sep = chr(ord("A"))
identifier = f"{user}{sep}{sys.version_info[0]}{sep}{sys.version_info[1]}"
return f"Z{hashify(identifier)}"
Expand Down
6 changes: 3 additions & 3 deletions tests/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -204,9 +204,9 @@ def test_headers_unclobbered_update(options_arg, no_fields):

# We arbitrarily chose a header to check it remains unchanged/unclobbered
# so should not be overwritten by a test case
assert (
invariant_header_name not in options_arg["headers"]
), f"{invariant_header_name} is checked as not being overwritten in this test"
assert invariant_header_name not in options_arg["headers"], (
f"{invariant_header_name} is checked as not being overwritten in this test"
)

# WHEN: we initialise the JIRA class and get the headers
jira_client = jira.client.JIRA(
Expand Down
4 changes: 2 additions & 2 deletions tests/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -637,7 +637,7 @@ def test_add_group(self):
self.assertEqual(
self.test_groupname,
x[0],
"Did not find expected group after trying to add" " it. Test Fails.",
"Did not find expected group after trying to add it. Test Fails.",
)
self.jira.remove_group(self.test_groupname)

Expand Down Expand Up @@ -722,7 +722,7 @@ def test_remove_user_from_group(self):
self.assertNotIn(
self.test_username,
x.keys(),
"Username found in group when it should have been removed. " "Test Fails.",
"Username found in group when it should have been removed. Test Fails.",
)

self.jira.remove_group(self.test_groupname)
Expand Down
Loading