Skip to content

Commit c0ce4eb

Browse files
[pre-commit.ci] pre-commit autoupdate (#167)
* [pre-commit.ci] pre-commit autoupdate updates: - [github.com/pre-commit/pre-commit-hooks: v4.6.0 → v5.0.0](pre-commit/pre-commit-hooks@v4.6.0...v5.0.0) - [github.com/adrienverge/yamllint.git: v1.35.1 → v1.37.0](https://github.com/adrienverge/yamllint.git/compare/v1.35.1...v1.37.0) - [github.com/astral-sh/ruff-pre-commit: v0.5.7 → v0.11.7](astral-sh/ruff-pre-commit@v0.5.7...v0.11.7) - [github.com/rhysd/actionlint: v1.7.1 → v1.7.7](rhysd/actionlint@v1.7.1...v1.7.7) * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * [pre-commit.ci] pre-commit autoupdate updates: - [github.com/pre-commit/pre-commit-hooks: v4.6.0 → v5.0.0](pre-commit/pre-commit-hooks@v4.6.0...v5.0.0) - [github.com/adrienverge/yamllint.git: v1.35.1 → v1.37.1](https://github.com/adrienverge/yamllint.git/compare/v1.35.1...v1.37.1) - [github.com/astral-sh/ruff-pre-commit: v0.5.7 → v0.11.8](astral-sh/ruff-pre-commit@v0.5.7...v0.11.8) - [github.com/rhysd/actionlint: v1.7.1 → v1.7.7](rhysd/actionlint@v1.7.1...v1.7.7) * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * checks * items * change logs --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: CP <[email protected]>
1 parent 477dfc9 commit c0ce4eb

File tree

31 files changed

+237
-66
lines changed

31 files changed

+237
-66
lines changed

.pre-commit-config.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# See https://pre-commit.com/hooks.html for more hooks
44
repos:
55
- repo: https://github.com/pre-commit/pre-commit-hooks
6-
rev: v4.6.0
6+
rev: v5.0.0
77
hooks:
88
- id: trailing-whitespace
99
- id: end-of-file-fixer
@@ -27,7 +27,7 @@ repos:
2727
- '80'
2828
- --preserve-quotes
2929
- repo: https://github.com/adrienverge/yamllint.git
30-
rev: v1.35.1
30+
rev: v1.37.1
3131
hooks:
3232
- id: yamllint
3333
args: [--format, parsable, -d, relaxed]
@@ -41,7 +41,7 @@ repos:
4141
additional_dependencies: ["gibberish_detector"]
4242
- repo: https://github.com/astral-sh/ruff-pre-commit
4343
# Ruff version.
44-
rev: 'v0.5.7'
44+
rev: 'v0.11.8'
4545
hooks:
4646
- id: ruff-format
4747
- id: ruff
@@ -65,7 +65,7 @@ repos:
6565
hooks:
6666
- id: shellcheck
6767
- repo: https://github.com/rhysd/actionlint
68-
rev: v1.7.1
68+
rev: v1.7.7
6969
hooks:
7070
- id: actionlint
7171
name: actionlint

conftest.py

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313

1414

1515
@pytest.fixture(scope="session")
16-
def django_db_modify_db_settings_pants_suffix() -> None: # noqa: PT004
16+
def django_db_modify_db_settings_pants_suffix() -> None:
1717
skip_if_no_django()
1818

1919
slot_id = environ.get("PANTS_EXECUTION_SLOT", None)
@@ -23,13 +23,13 @@ def django_db_modify_db_settings_pants_suffix() -> None: # noqa: PT004
2323

2424

2525
@pytest.fixture(scope="session")
26-
def django_db_modify_db_settings_parallel_suffix( # noqa: PT004
26+
def django_db_modify_db_settings_parallel_suffix(
2727
django_db_modify_db_settings_pants_suffix, # noqa: ARG001
2828
) -> None:
2929
skip_if_no_django()
3030

3131

32-
@pytest.fixture()
32+
@pytest.fixture
3333
def learner_drf_client(learner):
3434
"""DRF API test client that is authenticated with the user"""
3535
# import is here to avoid trying to load django before settings are initialized
@@ -40,7 +40,7 @@ def learner_drf_client(learner):
4040
return client
4141

4242

43-
@pytest.fixture()
43+
@pytest.fixture
4444
def learner(db): # noqa: ARG001
4545
"""Fixture for a default learner"""
4646
# import is here to avoid trying to load django before settings are initialized
@@ -49,7 +49,7 @@ def learner(db): # noqa: ARG001
4949
return UserFactory.create()
5050

5151

52-
@pytest.fixture()
52+
@pytest.fixture
5353
def learner_and_oauth2(learner):
5454
"""Fixture for a default learner and oauth2 records"""
5555
# import is here to avoid trying to load django before settings are initialized
@@ -75,31 +75,31 @@ def learner_and_oauth2(learner):
7575
)
7676

7777

78-
@pytest.fixture()
78+
@pytest.fixture
7979
def staff_user(db): # noqa: ARG001
8080
"""Staff user fixture"""
8181
from mitol.common.factories import UserFactory
8282

8383
return UserFactory.create(is_staff=True)
8484

8585

86-
@pytest.fixture()
86+
@pytest.fixture
8787
def user_client(learner):
8888
"""Django test client that is authenticated with the user"""
8989
client = Client()
9090
client.force_login(learner)
9191
return client
9292

9393

94-
@pytest.fixture()
94+
@pytest.fixture
9595
def staff_client(staff_user):
9696
"""Django test client that is authenticated with the staff user"""
9797
client = Client()
9898
client.force_login(staff_user)
9999
return client
100100

101101

102-
@pytest.fixture()
102+
@pytest.fixture
103103
def google_sheets_base_settings(settings):
104104
"""Fixture for base google sheets settings"""
105105
settings.MITOL_GOOGLE_SHEETS_ENROLLMENT_CHANGE_SHEET_ID = "1"
@@ -109,14 +109,14 @@ def google_sheets_base_settings(settings):
109109
return settings
110110

111111

112-
@pytest.fixture()
112+
@pytest.fixture
113113
def google_sheets_service_creds_settings(settings):
114114
"""Fixture for google sheets settings configured for a service account"""
115115
settings.MITOL_GOOGLE_SHEETS_DRIVE_SERVICE_ACCOUNT_CREDS = '{"credentials": "json"}'
116116
return settings
117117

118118

119-
@pytest.fixture()
119+
@pytest.fixture
120120
def google_sheets_client_creds_settings(settings):
121121
"""Fixture gor google sheets settings configured with OAuth"""
122122
settings.MITOL_GOOGLE_SHEETS_DRIVE_CLIENT_ID = "nhijg1i.apps.googleusercontent.com"
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
<!--
2+
A new scriv changelog fragment.
3+
4+
Uncomment the section that is right (remove the HTML comment wrapper).
5+
For top level release notes, leave all the headers commented out.
6+
-->
7+
8+
<!--
9+
### Removed
10+
11+
- A bullet item for the Removed category.
12+
13+
-->
14+
<!--
15+
### Added
16+
17+
- A bullet item for the Added category.
18+
19+
-->
20+
<!--
21+
### Changed
22+
23+
- pre-commit auto update fixes.
24+
-->
25+
<!--
26+
### Deprecated
27+
28+
- A bullet item for the Deprecated category.
29+
30+
-->
31+
<!--
32+
### Fixed
33+
34+
- A bullet item for the Fixed category.
35+
36+
-->
37+
<!--
38+
### Security
39+
40+
- A bullet item for the Security category.
41+
42+
-->

src/common/mitol/common/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def update(self, **kwargs):
3232
Automatically update updated_on timestamp when .update(). This is because .update()
3333
does not go through .save(), thus will not auto_now, because it happens on the
3434
database level without loading objects into memory.
35-
""" # noqa: E501, D402
35+
""" # noqa: E501
3636
if "updated_on" not in kwargs:
3737
kwargs["updated_on"] = now_in_utc()
3838
return super().update(**kwargs)

src/common/mitol/common/templatetags/render_bundle.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ def render_bundle(
6060
return _render_tags(bundle, added_attrs)
6161
except OSError:
6262
# webpack-stats.json doesn't exist
63-
return mark_safe("") # noqa: S308
63+
return mark_safe("")
6464

6565

6666
def _render_tags(bundle: Iterator[dict], added_attrs: str = "") -> SafeText:
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
<!--
2+
A new scriv changelog fragment.
3+
4+
Uncomment the section that is right (remove the HTML comment wrapper).
5+
For top level release notes, leave all the headers commented out.
6+
-->
7+
8+
<!--
9+
### Removed
10+
11+
- A bullet item for the Removed category.
12+
13+
-->
14+
<!--
15+
### Added
16+
17+
- A bullet item for the Added category.
18+
19+
-->
20+
<!--
21+
### Changed
22+
23+
- pre-commit auto update fixes.
24+
25+
-->
26+
<!--
27+
### Deprecated
28+
29+
- A bullet item for the Deprecated category.
30+
31+
-->
32+
<!--
33+
### Fixed
34+
35+
- A bullet item for the Fixed category.
36+
37+
-->
38+
<!--
39+
### Security
40+
41+
- A bullet item for the Security category.
42+
43+
-->

src/google_sheets_deferrals/mitol/google_sheets_deferrals/management/commands/process_deferral_requests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def handle(self, *args, **options): # noqa: ARG002
2424
deferral_request_handler = DeferralRequestHandler()
2525
self.stdout.write("Handling refunds and updating spreadsheet...")
2626
results = deferral_request_handler.process_sheet(
27-
limit_row_index=options.get("row", None)
27+
limit_row_index=options.get("row")
2828
)
2929
self.stdout.write(
3030
self.style.SUCCESS(f"Deferral sheet successfully processed.\n{results}")
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
<!--
2+
A new scriv changelog fragment.
3+
4+
Uncomment the section that is right (remove the HTML comment wrapper).
5+
For top level release notes, leave all the headers commented out.
6+
-->
7+
8+
<!--
9+
### Removed
10+
11+
- A bullet item for the Removed category.
12+
13+
-->
14+
<!--
15+
### Added
16+
17+
- A bullet item for the Added category.
18+
19+
-->
20+
<!--
21+
### Changed
22+
23+
- pre-commit auto update fixes.
24+
25+
-->
26+
<!--
27+
### Deprecated
28+
29+
- A bullet item for the Deprecated category.
30+
31+
-->
32+
<!--
33+
### Fixed
34+
35+
- A bullet item for the Fixed category.
36+
37+
-->
38+
<!--
39+
### Security
40+
41+
- A bullet item for the Security category.
42+
43+
-->

src/google_sheets_refunds/mitol/google_sheets_refunds/management/commands/process_refund_requests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def handle(self, *args, **options): # noqa: ARG002
2424
refund_request_handler = RefundRequestHandler()
2525
self.stdout.write("Handling refunds and updating spreadsheet...")
2626
results = refund_request_handler.process_sheet(
27-
limit_row_index=options.get("row", None)
27+
limit_row_index=options.get("row")
2828
)
2929
self.stdout.write(
3030
self.style.SUCCESS(f"Refund sheet successfully processed.\n{results}")
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
<!--
2+
A new scriv changelog fragment.
3+
4+
Uncomment the section that is right (remove the HTML comment wrapper).
5+
For top level release notes, leave all the headers commented out.
6+
-->
7+
8+
<!--
9+
### Removed
10+
11+
- A bullet item for the Removed category.
12+
13+
-->
14+
<!--
15+
### Added
16+
17+
- A bullet item for the Added category.
18+
19+
-->
20+
<!--
21+
### Changed
22+
23+
- pre-commit auto update fixes.
24+
25+
-->
26+
<!--
27+
### Deprecated
28+
29+
- A bullet item for the Deprecated category.
30+
31+
-->
32+
<!--
33+
### Fixed
34+
35+
- A bullet item for the Fixed category.
36+
37+
-->
38+
<!--
39+
### Security
40+
41+
- A bullet item for the Security category.
42+
43+
-->

0 commit comments

Comments
 (0)