diff --git a/config/config.py b/config/config.py index f17a699..54b143b 100644 --- a/config/config.py +++ b/config/config.py @@ -1,8 +1,7 @@ -""" -Configuration module for the Datacosmos SDK. +"""Configuration module for the Datacosmos SDK. -This module provides configuration management using Pydantic and Pydantic Settings. -It loads default values, allows overrides via YAML configuration files, +Handles configuration management using Pydantic and Pydantic Settings. +It loads default values, allows overrides via YAML configuration files, and supports environment variable-based overrides. """ @@ -70,7 +69,7 @@ def from_yaml(cls, file_path: str = "config/config.yaml") -> "Config": def merge_with_env(cls, values): """Override settings with environment variables if set. - This method checks if any environment variables corresponding to the + This method checks if any environment variables corresponding to the config fields are set and updates their values accordingly. Args: diff --git a/config/models/m2m_authentication_config.py b/config/models/m2m_authentication_config.py index 5e23828..0afca20 100644 --- a/config/models/m2m_authentication_config.py +++ b/config/models/m2m_authentication_config.py @@ -1,8 +1,7 @@ -""" -Module for configuring machine-to-machine (M2M) authentication. +"""Module for configuring machine-to-machine (M2M) authentication. -This configuration is used when running scripts in the cluster that require -automated authentication without user interaction. +Used when running scripts in the cluster that require automated authentication +without user interaction. """ from typing import Literal diff --git a/config/models/url.py b/config/models/url.py index b9eca5d..7df9c83 100644 --- a/config/models/url.py +++ b/config/models/url.py @@ -1,8 +1,7 @@ -""" -Module defining a URL configuration model. +"""Module defining a structured URL configuration model. -This module provides a structured way to handle URLs, ensuring they -contain required components such as protocol, host, port, and path. +Ensures that URLs contain required components such as protocol, host, +port, and path. """ from common.domain.url import URL as DomainURL diff --git a/datacosmos/client.py b/datacosmos/client.py index ff59f38..d68c0d1 100644 --- a/datacosmos/client.py +++ b/datacosmos/client.py @@ -29,7 +29,7 @@ def __init__( ): """Initialize the DatacosmosClient. - Load configuration from the specified YAML file, environment variables, + Load configuration from the specified YAML file, environment variables, or fallback to the default values provided in the `Config` class. """ self.logger = logging.getLogger(__name__) diff --git a/datacosmos/stac/__init__.py b/datacosmos/stac/__init__.py index aa016c4..e87992f 100644 --- a/datacosmos/stac/__init__.py +++ b/datacosmos/stac/__init__.py @@ -1,7 +1,5 @@ -""" -STAC package for interacting with the STAC API. +"""STAC package for interacting with the STAC API, providing query and fetch functionalities. -This package provides functionalities to query, fetch, and interact -with STAC (SpatioTemporal Asset Catalog) services using an authenticated -Datacosmos client. +It enables interaction with STAC (SpatioTemporal Asset Catalog) services +using an authenticated Datacosmos client. """ diff --git a/datacosmos/stac/models/search_parameters.py b/datacosmos/stac/models/search_parameters.py index af3868b..8dd74d3 100644 --- a/datacosmos/stac/models/search_parameters.py +++ b/datacosmos/stac/models/search_parameters.py @@ -1,9 +1,6 @@ -""" -Module defining the SearchParameters model for STAC API queries. +"""Module defining the SearchParameters model for STAC API queries, encapsulating filtering criteria. -This module contains the `SearchParameters` model, which encapsulates -filtering criteria for searching STAC items, such as spatial, temporal, -and property-based filters. +It includes spatial, temporal, and property-based filters for querying STAC items efficiently. """ from typing import Optional, Union diff --git a/datacosmos/stac/stac_client.py b/datacosmos/stac/stac_client.py index 4bd1ad1..2799178 100644 --- a/datacosmos/stac/stac_client.py +++ b/datacosmos/stac/stac_client.py @@ -1,7 +1,6 @@ -""" -STAC Client module. +"""STAC Client module for interacting with a STAC (SpatioTemporal Asset Catalog) API. -This module provides a client to interact with a STAC (SpatioTemporal Asset Catalog) API. +Provides methods for querying, fetching, and paginating STAC items. """ from typing import Generator, Optional