Skip to content

Commit 2ff0ead

Browse files
committed
Make S3 region mandatory
1 parent 1b98386 commit 2ff0ead

File tree

3 files changed

+3
-2
lines changed

3 files changed

+3
-2
lines changed
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Make S3 connection ``region`` a mandatory option.

syncmaster/dto/connections.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,8 +175,8 @@ class S3ConnectionDTO(ConnectionDTO):
175175
secret_key: str
176176
bucket: str
177177
bucket_style: Literal["domain", "path"]
178+
region: str
178179
additional_params: dict = field(default_factory=dict)
179-
region: str | None = None
180180
protocol: str = "https"
181181
type: ClassVar[str] = "s3"
182182

syncmaster/schemas/v1/connections/s3.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ class ReadS3ConnectionDataSchema(BaseModel):
2020
host: str
2121
bucket: str
2222
protocol: Literal["http", "https"] = "https"
23+
region: str
2324
port: int | None = Field(default=None, gt=0, le=65535, validate_default=True) # noqa: WPS432
24-
region: str | None = None
2525
bucket_style: Literal["domain", "path"] = "path"
2626
additional_params: dict = Field(default_factory=dict)
2727

0 commit comments

Comments
 (0)