Skip to content

Commit d4a9e90

Browse files
chore(pre-commit.ci): Apply pre-commit autoupdate (#873)
1 parent 93bd555 commit d4a9e90

File tree

4 files changed

+12
-12
lines changed

4 files changed

+12
-12
lines changed

.pre-commit-config.yaml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -43,13 +43,13 @@ repos:
4343

4444
# Detect hardcoded secrets
4545
- repo: https://github.com/gitleaks/gitleaks
46-
rev: v8.24.0
46+
rev: v8.24.2
4747
hooks:
4848
- id: gitleaks
4949

5050
# Dockerfile
5151
- repo: https://github.com/hadolint/hadolint
52-
rev: v2.12.1-beta
52+
rev: v2.13.1-beta
5353
hooks:
5454
- id: hadolint
5555

@@ -66,7 +66,7 @@ repos:
6666
- --implicit_start
6767

6868
- repo: https://github.com/adrienverge/yamllint.git
69-
rev: v1.36.2
69+
rev: v1.37.0
7070
hooks:
7171
- id: yamllint
7272
types:
@@ -77,7 +77,7 @@ repos:
7777

7878
# JSON5
7979
- repo: https://github.com/pre-commit/mirrors-prettier
80-
rev: v3.1.0
80+
rev: v4.0.0-alpha.8
8181
hooks:
8282
- id: prettier
8383
# https://prettier.io/docs/en/options.html#parser
@@ -99,7 +99,7 @@ repos:
9999

100100
# Python
101101
- repo: https://github.com/astral-sh/ruff-pre-commit
102-
rev: v0.8.4
102+
rev: v0.11.4
103103
hooks:
104104
- id: ruff
105105
args:

src/pre_commit_terraform/_cli.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def invoke_cli_app(cli_args: list[str]) -> ReturnCodeType:
2828
root_cli_parser = initialize_argument_parser()
2929
parsed_cli_args = root_cli_parser.parse_args(cli_args)
3030
invoke_cli_app = cast_to(
31-
# FIXME: attempt typing per https://stackoverflow.com/a/75666611/595220 # noqa: TD001, TD002, TD003, FIX001, E501 All these suppressions caused by "FIXME" comment
31+
# FIXME: attempt typing per https://stackoverflow.com/a/75666611/595220 # noqa: TD001, TD002, FIX001, E501 All these suppressions caused by "FIXME" comment
3232
'CLIAppEntryPointCallableType',
3333
parsed_cli_args.invoke_cli_app,
3434
)
@@ -38,24 +38,24 @@ def invoke_cli_app(cli_args: list[str]) -> ReturnCodeType:
3838
except PreCommitTerraformExit as exit_err:
3939
# T201 - FIXME here and below - we will replace 'print' with
4040
# logging later
41-
print(f'App exiting: {exit_err !s}', file=sys.stderr) # noqa: T201
41+
print(f'App exiting: {exit_err!s}', file=sys.stderr) # noqa: T201
4242
raise
4343
except PreCommitTerraformRuntimeError as unhandled_exc:
4444
print( # noqa: T201
45-
f'App execution took an unexpected turn: {unhandled_exc !s}. '
45+
f'App execution took an unexpected turn: {unhandled_exc!s}. '
4646
'Exiting...',
4747
file=sys.stderr,
4848
)
4949
return ReturnCode.ERROR
5050
except PreCommitTerraformBaseError as unhandled_exc:
5151
print( # noqa: T201
52-
f'A surprising exception happened: {unhandled_exc !s}. Exiting...',
52+
f'A surprising exception happened: {unhandled_exc!s}. Exiting...',
5353
file=sys.stderr,
5454
)
5555
return ReturnCode.ERROR
5656
except KeyboardInterrupt as ctrl_c_exc:
5757
print( # noqa: T201
58-
f'User-initiated interrupt: {ctrl_c_exc !s}. Exiting...',
58+
f'User-initiated interrupt: {ctrl_c_exc!s}. Exiting...',
5959
file=sys.stderr,
6060
)
6161
return ReturnCode.ERROR

src/pre_commit_terraform/_cli_parsing.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ def initialize_argument_parser() -> ArgumentParser:
3737
Returns:
3838
ArgumentParser: The root parser with sub-commands attached.
3939
"""
40-
root_cli_parser = ArgumentParser(prog=f'python -m {__package__ !s}')
40+
root_cli_parser = ArgumentParser(prog=f'python -m {__package__!s}')
4141
attach_subcommand_parsers_to(root_cli_parser)
4242
return root_cli_parser
4343

tests/pytest/_cli_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def invoke_cli_app(self, parsed_cli_args: Namespace) -> ReturnCodeType:
6969
assert invoke_cli_app(['sentinel']) == ReturnCode.ERROR
7070

7171
captured_outputs = capsys.readouterr()
72-
assert captured_outputs.err == f'{expected_stderr !s}\n'
72+
assert captured_outputs.err == f'{expected_stderr!s}\n'
7373

7474

7575
def test_app_exit(

0 commit comments

Comments
 (0)