Skip to content
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
3 changes: 1 addition & 2 deletions sdk/src/opendecree/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
UnavailableError,
UnimplementedError,
)
from opendecree.types import Change, ConfigValue, FieldUpdate, ServerVersion
from opendecree.types import Change, FieldUpdate, ServerVersion
from opendecree.watcher import ConfigWatcher, WatchedField

__all__ = [
Expand All @@ -44,7 +44,6 @@
"Change",
"ChecksumMismatchError",
"ConfigClient",
"ConfigValue",
"ConfigWatcher",
"DecreeError",
"FieldUpdate",
Expand Down
17 changes: 0 additions & 17 deletions sdk/src/opendecree/types.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,23 +8,6 @@
from dataclasses import dataclass


@dataclass(frozen=True, slots=True)
class ConfigValue:
"""A single configuration value.

Attributes:
field_path: Dot-separated field path (e.g., ``"payments.fee"``).
value: The raw string value.
checksum: xxHash checksum of the value.
description: Optional description set when the value was written.
"""

field_path: str
value: str
checksum: str
description: str = ""


@dataclass(frozen=True, slots=True)
class Change:
"""A configuration change event from a subscription.
Expand Down
10 changes: 1 addition & 9 deletions sdk/tests/test_types.py
Original file line number Diff line number Diff line change
@@ -1,14 +1,6 @@
"""Tests for public data types."""

from opendecree.types import Change, ConfigValue, ServerVersion


def test_config_value_frozen():
cv = ConfigValue(field_path="a.b", value="1", checksum="abc")
assert cv.field_path == "a.b"
assert cv.value == "1"
assert cv.checksum == "abc"
assert cv.description == ""
from opendecree.types import Change, ServerVersion


def test_change():
Expand Down