Skip to content
This repository has been archived by the owner on Jun 18, 2024. It is now read-only.

Pin rio tiler to 6.2.3.post1 (#57) #59

Merged
merged 8 commits into from
Nov 16, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 2 additions & 26 deletions raster_api/infrastructure/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,6 @@
from pydantic import BaseSettings, Field


class MyConfig(BaseSettings.Config):
"""Custom config class that support multiple env_prefixes"""

@classmethod
def prepare_field(cls, field) -> None:
"""Workaround to not overwrite ENV_PREFIX"""
if "env_names" in field.field_info.extra:
return
return super().prepare_field(field)


class vedaRasterSettings(BaseSettings):
"""Raster settings"""

Expand Down Expand Up @@ -90,24 +79,11 @@ class vedaRasterSettings(BaseSettings):
description="Complete url of custom host including subdomain. When provided, override host in api integration",
)

class Config(MyConfig):
class Config:
"""model config"""

env_file = ".env"
env_prefix = "VEDA_"


class Settings(vedaRasterSettings):
"""Application Settings"""

host: Optional[str] = Field(
"",
description="Optional host to send to raster api", # propagate cf url to raster api
)

class Config(MyConfig):
"Model config"
env_prefix = "VEDA_"


veda_raster_settings = Settings()
veda_raster_settings = vedaRasterSettings()
1 change: 1 addition & 0 deletions raster_api/runtime/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
"starlette-cramjam>=0.3,<0.4",
"aws_xray_sdk>=2.6.0,<3",
"aws-lambda-powertools>=1.18.0",
"rio-tiler==6.2.3.post1",
]

extra_reqs = {
Expand Down