prole/knoe/state.py
chrisfu 4ee2b259c9 Checkpoint: rename installer to knoe + harden db build context
- Add build-context helper to copy Docker context safely (ignore runtime data, keep symlinks)

- Update UI and core actions to use ~/.prole/build and shared copy helper

- Add/adjust tests and scripts; introduce knoe ops helpers and update manifests

Co-authored-by: Junie <junie@jetbrains.com>
2026-03-22 01:45:21 -07:00

25 lines
780 B
Python

"""State model for the UI-agnostic installer core."""
from __future__ import annotations
from dataclasses import dataclass, field
from typing import Any
@dataclass
class InstallerState:
current_id: str | None = None
data: dict[str, Any] = field(default_factory=dict)
inputs: dict[str, Any] = field(default_factory=dict)
config_data: dict[str, Any] = field(default_factory=dict)
errors: list[str] = field(default_factory=list)
progress: dict[str, float] = field(default_factory=dict)
history: list[str] = field(default_factory=list)
completed: set[str] = field(default_factory=set)
# Execution engine / controller
controller: Any = None
def mark_completed(self, milestone_id: str) -> None:
self.completed.add(milestone_id)