Skip to content

Polishing CLI#77

Merged
Tiendil merged 6 commits into
mainfrom
feature/polishing-cli
May 16, 2026
Merged

Polishing CLI#77
Tiendil merged 6 commits into
mainfrom
feature/polishing-cli

Conversation

@Tiendil

@Tiendil Tiendil commented May 16, 2026

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI review requested due to automatic review settings May 16, 2026 14:42

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR polishes the Donna CLI by flattening its command structure (removing the workspaces, sessions, and artifacts command groups in favor of top-level commands like init, start, run, list, etc.) and refactors the supporting domain types. It introduces a typed path system (donna/domain/paths.py), splits artifact/section identifiers into helper-driven NewTypes, replaces time-based caching with file-fingerprint-based caching, and accepts root-anchored, relative, or absolute project paths in artifact arguments.

Changes:

  • Flatten CLI subcommands and rename action-request-completed to complete-action-request; entry point now uses donna.cli.application:main which registers commands lazily.
  • Introduce donna/domain/paths.py typed paths and a new donna/workspaces/paths.py resolver; rewrite artifact_ids around NewType plus helper functions (artifact_section_id, split_artifact_section_id, etc.) and let artifact CLI args accept relative/absolute paths.
  • Replace the time-based TimedCache with a FileFingerprint-based cache for artifacts/state, drop the cache_lifetime config option, and add SessionStateChangedExternally error; initialization writes a TOML fixture and no longer eagerly creates the session dir.

Reviewed changes

Copilot reviewed 46 out of 46 changed files in this pull request and generated no comments.

Show a summary per file
File Description
README.md Update CLI examples to flattened command names and explain lazy session dir.
pyproject.toml Point entry point at donna.cli.application:main.
donna/cli/main.py Delegate to main() instead of importing commands here.
donna/cli/application.py Add main() that registers commands and runs app.
donna/cli/commands/{workspaces,sessions,artifacts}.py Drop sub-Typers and register commands directly on app; parse path arguments through new helpers.
donna/cli/types.py Replace ID parsers with raw-string parsers and parse_artifact_*_argument resolution helpers.
donna/cli/{entities,utils}.py Use new UntrustedPath/PathInput types.
donna/domain/paths.py New NewType-based path taxonomy.
donna/domain/artifact_ids.py Rewrite IDs as NewType plus validation/split/build helpers.
donna/domain/types.py Remove Milliseconds.
donna/workspaces/paths.py New module for resolving and normalizing project paths.
donna/workspaces/initialization.py Write fixture-based config; remove eager session-dir creation.
donna/workspaces/fixtures/base_config.toml New default config fixture.
donna/workspaces/{config,errors,artifacts,sessions}.py Switch to new typed paths and helper APIs; add fingerprint-based artifact API.
donna/workspaces/files.py New FileFingerprint value object.
donna/context/{artifacts,state,primitives}.py Replace timed cache with fingerprint cache; add external-change detection.
donna/context/entity_cache.py Removed.
donna/machine/{tasks,state,sessions,errors}.py Use split_artifact_section_id/artifact_section_id; add SessionStateChangedExternally.
donna/primitives/{artifacts,directives,sections}/*.py Adopt new artifact-section helpers.
donna/core/utils.py Return ProjectRootPath from discovery helpers.
donna/skills/fixtures/*.md Update agent skill docs to flattened CLI.
donna.toml Drop cache_lifetime.
.agents/donna/, .agents/skills/ Remove obsolete agent docs and skills.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Tiendil Tiendil merged commit 1a55603 into main May 16, 2026
5 checks passed
@Tiendil Tiendil deleted the feature/polishing-cli branch May 16, 2026 14:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants