Skip to content

Commit b174d91

Browse files
committed
update dependencies
1 parent 1de6cd0 commit b174d91

File tree

5 files changed

+19
-19
lines changed

5 files changed

+19
-19
lines changed

.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
repos:
22
- repo: https://github.com/rhysd/actionlint
3-
rev: v1.7.5
3+
rev: v1.7.7
44
hooks:
55
- id: actionlint-docker
66
- repo: https://github.com/antonbabenko/pre-commit-terraform
7-
rev: v1.96.3
7+
rev: v1.97.1
88
hooks:
99
- id: terraform_fmt
1010
# - id: terraform_docs
1111
# args: ['--sort-by-required', '--no-providers']
1212
- repo: https://github.com/astral-sh/ruff-pre-commit
13-
rev: v0.8.4
13+
rev: v0.9.4
1414
hooks:
1515
- id: ruff
1616
args: [--fix]

policy_sentry/command/create_template.py

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
from __future__ import annotations
77

88
import logging
9+
import sys
910
from pathlib import Path
1011

1112
import click
@@ -49,17 +50,16 @@ def create_template(output_file: str | Path, template_type: str, verbose: str) -
4950
log_level = getattr(logging, verbose.upper())
5051
set_stream_logger(level=log_level)
5152

52-
filename = Path(output_file).resolve()
5353
if template_type == "actions":
54-
actions_template = create_actions_template()
55-
with open(filename, "a", encoding="utf-8") as file_obj:
56-
for line in actions_template:
57-
file_obj.write(line)
54+
template = create_actions_template()
55+
elif template_type == "crud":
56+
template = create_crud_template()
57+
else:
58+
print(f"Unknown template type: {template_type}")
59+
sys.exit()
5860

59-
if template_type == "crud":
60-
crud_template = create_crud_template()
61-
with open(filename, "a", encoding="utf-8") as file_obj:
62-
for line in crud_template:
63-
file_obj.write(line)
61+
filename = Path(output_file).resolve()
62+
with open(filename, "a", encoding="utf-8") as file_obj:
63+
file_obj.write(template)
6464

6565
print(f"write-policy template file written to: {filename}")

requirements-dev.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
# CI
2-
pre-commit==4.0.1
2+
pre-commit==4.1.0
33
# Unit Testing
44
pytest==8.3.4
5-
coverage==7.6.8
5+
coverage==7.6.10
66
# Integration tests and tasks
77
invoke==2.2.0
88
# Type hints
99
mypy[faster-cache]==1.14.1
10-
types-pyyaml==6.0.12.20240917
10+
types-pyyaml==6.0.12.20241230
1111
types-requests==2.32.0.20241016
1212
types-beautifulsoup4==4.12.0.20241020

requirements.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
# Command line
2-
click==8.1.7
2+
click==8.1.8
33
# Web Scraping
44
beautifulsoup4==4.12.3
55
requests==2.32.3
66
# Config files and schema validation
77
PyYAML==6.0.2
88
schema==0.7.7
99
# IAM DB
10-
orjson==3.10.12
10+
orjson==3.10.15

tasks.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ def query(c):
173173
pty=True,
174174
)
175175
c.run(
176-
"./policy_sentry/bin/cli.py query action-table " "--service ram --access-level permissions-management",
176+
"./policy_sentry/bin/cli.py query action-table --service ram --access-level permissions-management",
177177
pty=True,
178178
)
179179
c.run(

0 commit comments

Comments
 (0)