Skip to content

Commit

Permalink
Issue #112 Remove now unused AggregatorConfig definition
Browse files Browse the repository at this point in the history
  • Loading branch information
soxofaan committed Mar 4, 2024
1 parent 6f8e8a8 commit 15ee0a8
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 24 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.

The format is roughly based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).

## [0.28.0]

- Remove (now unused) `AggregatorConfig` class definition ([#112](https://github.com/Open-EO/openeo-aggregator/issues/112))

## [0.27.0]

- Remove deprecated `AggregatorConfig` fields: `aggregator_backends`, `partitioned_job_tracking`,
Expand Down
2 changes: 1 addition & 1 deletion src/openeo_aggregator/about.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
import sys
from typing import Optional

__version__ = "0.27.1a1"
__version__ = "0.28.0a1"


def log_version_info(logger: Optional[logging.Logger] = None):
Expand Down
11 changes: 2 additions & 9 deletions src/openeo_aggregator/config.py
Original file line number Diff line number Diff line change
@@ -1,15 +1,13 @@
import logging
import os
import re
from pathlib import Path
from typing import Callable, Dict, List, Optional, Union
from typing import Dict, List, Optional, Union

import attrs
from openeo_driver.config import OpenEoBackendConfig
from openeo_driver.config.load import ConfigGetter
from openeo_driver.server import build_backend_deploy_metadata
from openeo_driver.users.oidc import OidcProvider
from openeo_driver.utils import dict_item, smart_bool
from openeo_driver.utils import smart_bool

import openeo_aggregator.about

Expand All @@ -32,11 +30,6 @@ class ConfigException(ValueError):
pass


class AggregatorConfig(dict):
# TODO #112 Remove this empty shell
config_source = dict_item()


@attrs.frozen(kw_only=True)
class AggregatorBackendConfig(OpenEoBackendConfig):

Expand Down
14 changes: 0 additions & 14 deletions tests/test_config.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,8 @@
import textwrap

import pytest

from openeo_aggregator.config import AggregatorBackendConfig


def _get_config_content(config_var_name: str = "config"):
return textwrap.dedent(
f"""
from openeo_aggregator.config import AggregatorConfig
{config_var_name} = AggregatorConfig(
config_source=__file__,
test_dummy="bob",
)
"""
)


def test_config_defaults():
with pytest.raises(TypeError, match="missing.*required.*aggregator_backends"):
_ = AggregatorBackendConfig()
Expand Down

0 comments on commit 15ee0a8

Please sign in to comment.