Skip to content

Commit f63d46f

Browse files
authored
Merge branch 'main' into fix-linter
2 parents 973af47 + 7033567 commit f63d46f

File tree

11 files changed

+85
-96
lines changed

11 files changed

+85
-96
lines changed

scaleway-async/pyproject.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ ignore = ["E501"]
4242
select = [
4343
"ASYNC", # https://docs.astral.sh/ruff/rules/#flake8-async-async
4444
"B", # https://docs.astral.sh/ruff/rules/#flake8-bugbear-b
45+
"DTZ", # https://docs.astral.sh/ruff/rules/#flake8-datetimez-dtz
4546
"ERA", # https://docs.astral.sh/ruff/rules/#eradicate-era
4647
"EXE",# https://docs.astral.sh/ruff/rules/#flake8-executable-exe
4748
"F",# https://docs.astral.sh/ruff/rules/#pyflakes-f

scaleway-async/tests/utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import random
22
import uuid
3-
from datetime import datetime
3+
from datetime import datetime, timezone
44
from typing import Union
55

66
from scaleway_core.profile import ProfileDefaults
@@ -19,7 +19,7 @@ def random_access_key() -> str:
1919

2020

2121
def string_to_datetime(date: str) -> datetime:
22-
return datetime.strptime(date, "%Y-%m-%dT%H:%M:%SZ")
22+
return datetime.strptime(date, "%Y-%m-%dT%H:%M:%SZ").astimezone(timezone.utc)
2323

2424

2525
def random_date(min: Union[str, datetime], max: Union[str, datetime]) -> datetime:

scaleway-core/poetry.lock

Lines changed: 52 additions & 46 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

scaleway-core/pyproject.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ types-python-dateutil = "^2.8.19"
3333
ruff = ">=0.5.0,<0.12.8"
3434
mypy = "^1.5.1"
3535
ty = "^0.0.1a15"
36-
pyrefly = "^0.24.2"
36+
pyrefly = ">=0.24.2,<0.27.0"
3737

3838
[build-system]
3939
requires = ["poetry-core"]
@@ -47,7 +47,6 @@ ignore = [
4747
"BLE", # flake8-blind-except
4848
"C90", # mccabe
4949
"COM", # flake8-commas
50-
"DTZ", # flake8-datetimez
5150
"E501",
5251
"EM", # flake8-errmsg
5352
"FA", # flake8-future-annotations
@@ -59,7 +58,6 @@ ignore = [
5958
"PERF", # Perflint
6059
"PL", # Pylint
6160
"PT", # flake8-pytest-style
62-
"RUF", # Ruff-specific rules
6361
"S", # flake8-bandit
6462
"SIM", # flake8-simplify
6563
"SLF", # flake8-self
@@ -70,6 +68,7 @@ select = [
7068
"ARG", # https://docs.astral.sh/ruff/rules/#flake8-unused-arguments-arg
7169
"ASYNC", # https://docs.astral.sh/ruff/rules/#flake8-async-async
7270
"C4", # https://docs.astral.sh/ruff/rules/#flake8-comprehensions-c4
71+
"DTZ", # https://docs.astral.sh/ruff/rules/#flake8-datetimez-dtz
7372
"ERA", # https://docs.astral.sh/ruff/rules/#eradicate-era
7473
"EXE", # https://docs.astral.sh/ruff/rules/#flake8-executable-exe
7574
"F", # https://docs.astral.sh/ruff/rules/#pyflakes-f
@@ -86,6 +85,7 @@ select = [
8685
"Q", # https://docs.astral.sh/ruff/rules/#flake8-quotes-q
8786
"RET", # https://docs.astral.sh/ruff/rules/#flake8-return-ret
8887
"RSE", # https://docs.astral.sh/ruff/rules/#flake8-raise-rse
88+
"RUF", # https://docs.astral.sh/ruff/rules/#ruff-specific-rules-ruf
8989
"SLOT", # https://docs.astral.sh/ruff/rules/#flake8-slots-slot
9090
"T10", # https://docs.astral.sh/ruff/rules/#flake8-debugger-t10
9191
"T20", # https://docs.astral.sh/ruff/rules/#flake8-print-t20

scaleway-core/scaleway_core/bridge/__init__.py

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -26,25 +26,25 @@
2626
from .decimal import marshal_Decimal
2727

2828
__all__ = [
29-
"Money",
30-
"unmarshal_Money",
31-
"marshal_Money",
32-
"Region",
3329
"ALL_REGIONS",
34-
"Zone",
3530
"ALL_ZONES",
31+
"Money",
32+
"Region",
3633
"ScwFile",
37-
"unmarshal_ScwFile",
38-
"marshal_ScwFile",
3934
"ServiceInfo",
40-
"unmarshal_ServiceInfo",
41-
"marshal_ServiceInfo",
42-
"TimeSeriesPoint",
4335
"TimeSeries",
44-
"unmarshal_TimeSeries",
36+
"TimeSeriesPoint",
37+
"Zone",
38+
"marshal_Decimal",
39+
"marshal_Money",
40+
"marshal_ScwFile",
41+
"marshal_ServiceInfo",
4542
"marshal_TimeSeries",
46-
"unmarshal_TimeSeriesPoint",
4743
"marshal_TimeSeriesPoint",
4844
"unmarshal_Decimal",
49-
"marshal_Decimal",
45+
"unmarshal_Money",
46+
"unmarshal_ScwFile",
47+
"unmarshal_ServiceInfo",
48+
"unmarshal_TimeSeries",
49+
"unmarshal_TimeSeriesPoint",
5050
]

scaleway-core/scaleway_core/profile/__init__.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,15 @@
1111
from .profile import Profile, ProfileConfig, ProfileDefaults
1212

1313
__all__ = [
14-
"Profile",
15-
"ProfileConfig",
16-
"ProfileDefaults",
17-
"ENV_KEY_SCW_CONFIG_PATH",
1814
"ENV_KEY_SCW_ACCESS_KEY",
19-
"ENV_KEY_SCW_SECRET_KEY",
2015
"ENV_KEY_SCW_API_URL",
16+
"ENV_KEY_SCW_CONFIG_PATH",
2117
"ENV_KEY_SCW_DEFAULT_ORGANIZATION_ID",
2218
"ENV_KEY_SCW_DEFAULT_PROJECT_ID",
2319
"ENV_KEY_SCW_DEFAULT_REGION",
2420
"ENV_KEY_SCW_DEFAULT_ZONE",
21+
"ENV_KEY_SCW_SECRET_KEY",
22+
"Profile",
23+
"ProfileConfig",
24+
"ProfileDefaults",
2525
]

scaleway-core/scaleway_core/utils/__init__.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,16 +21,16 @@
2121
)
2222

2323
__all__ = [
24+
"OneOfPossibility",
25+
"StrEnumMeta",
26+
"WaitForOptions",
27+
"WaitForStopCondition",
2428
"fetch_all_pages",
2529
"fetch_all_pages_async",
2630
"project_or_organization_id",
2731
"random_name",
28-
"OneOfPossibility",
2932
"resolve_one_of",
30-
"StrEnumMeta",
3133
"validate_path_param",
32-
"WaitForOptions",
33-
"WaitForStopCondition",
3434
"wait_for_resource",
3535
"wait_for_resource_async",
3636
]

0 commit comments

Comments
 (0)