Phase 0: repository structure, config model, and shared cache identity #2

Closed
opened 2026-04-11 18:15:48 +09:00 by mschoi · 6 comments
Owner

Goal

Lay down the repository, package, and config foundations for Sessions without overcommitting to heavyweight remote-daemon architecture.

Implementation Checklist

  • Create the initial mono-repo structure for:
    • Sublime package code
    • Rust local bridge
    • Rust session helper
    • docs/planning material
  • Decide the minimum supported Sublime build and Python environment
  • Define the canonical package name: Sessions
  • Define the core workspace identity:
    • remote host identity
    • remote root
    • optional profile
  • Define the cache identity so it is independent of the local machine identity
  • Split metadata into:
    • shared cache metadata
    • local-only runtime/session metadata
  • Define the settings model:
    • ssh config usage
    • recent workspaces
    • optional shared cache root
    • language/toolchain-specific settings
  • Define project file responsibilities vs plugin-owned metadata responsibilities
  • Define versioning and migration strategy for cache/metadata layout

Edge Cases and Test Scope

  • Same remote root accessed through different ssh aliases
  • Same ssh host with multiple remote roots
  • Remote root renamed or moved on the server
  • Shared cache root not available on startup
  • Windows/macOS path normalization differences for the same workspace identity
  • Cache key collisions caused by hostname aliases, symlinks, or user aliases
  • Upgrade path when metadata version changes
  • Empty or malformed ~/.ssh/config

Manual UI / Product Decisions

  • Keep initial settings surface minimal and avoid inventing a parallel ssh config format
  • Treat .sublime-project as the editor entry point, but keep plugin metadata as the source of truth
  • Do not store persistent session/chat state on the remote server
  • Default to local cache; make shared cache optional, not required

Current Status

  • Completed in commits: 3210e84, 27067f3, dee70e7, 7ef0e40, 5100c7c, 6cc9d23, dd5dc4a, 1c8f70b
  • Done: repo skeleton, Rust bridge/helper crate placeholders, workspace/cache identity, metadata split, settings model, project entry vs plugin metadata boundary, Linux-only Python/Rust CI baselines, stricter Python/Rust documentation standards applied to existing implementation boundaries, repository-wide Ruff enforcement for Google-style docstrings and 88-column formatting, explicit Sublime/Python runtime floor helpers, metadata version reset rules, and shared-cache fallback behavior
  • Edge/test coverage now explicitly tracks alias/root identity differentiation, remote-root move/rename changes, shared-cache-unavailable startup fallback, local-path-independent workspace identity, alias/symlink-like collision avoidance, metadata version mismatch resets, and empty-or-aliasless SSH config parsing
  • Remaining: none
## Goal Lay down the repository, package, and config foundations for `Sessions` without overcommitting to heavyweight remote-daemon architecture. ## Implementation Checklist - [x] Create the initial mono-repo structure for: - Sublime package code - Rust local bridge - Rust session helper - docs/planning material - [x] Decide the minimum supported Sublime build and Python environment - [x] Define the canonical package name: `Sessions` - [x] Define the core workspace identity: - remote host identity - remote root - optional profile - [x] Define the cache identity so it is independent of the local machine identity - [x] Split metadata into: - shared cache metadata - local-only runtime/session metadata - [x] Define the settings model: - ssh config usage - recent workspaces - optional shared cache root - language/toolchain-specific settings - [x] Define project file responsibilities vs plugin-owned metadata responsibilities - [x] Define versioning and migration strategy for cache/metadata layout ## Edge Cases and Test Scope - [x] Same remote root accessed through different ssh aliases - [x] Same ssh host with multiple remote roots - [x] Remote root renamed or moved on the server - [x] Shared cache root not available on startup - [x] Windows/macOS path normalization differences for the same workspace identity - [x] Cache key collisions caused by hostname aliases, symlinks, or user aliases - [x] Upgrade path when metadata version changes - [x] Empty or malformed `~/.ssh/config` ## Manual UI / Product Decisions - [x] Keep initial settings surface minimal and avoid inventing a parallel ssh config format - [x] Treat `.sublime-project` as the editor entry point, but keep plugin metadata as the source of truth - [x] Do not store persistent session/chat state on the remote server - [x] Default to local cache; make shared cache optional, not required ## Current Status - Completed in commits: `3210e84`, `27067f3`, `dee70e7`, `7ef0e40`, `5100c7c`, `6cc9d23`, `dd5dc4a`, `1c8f70b` - Done: repo skeleton, Rust bridge/helper crate placeholders, workspace/cache identity, metadata split, settings model, project entry vs plugin metadata boundary, Linux-only Python/Rust CI baselines, stricter Python/Rust documentation standards applied to existing implementation boundaries, repository-wide Ruff enforcement for Google-style docstrings and 88-column formatting, explicit Sublime/Python runtime floor helpers, metadata version reset rules, and shared-cache fallback behavior - Edge/test coverage now explicitly tracks alias/root identity differentiation, remote-root move/rename changes, shared-cache-unavailable startup fallback, local-path-independent workspace identity, alias/symlink-like collision avoidance, metadata version mismatch resets, and empty-or-aliasless SSH config parsing - Remaining: none
mschoi added this to the Phase 0 - Foundation milestone 2026-04-11 18:15:48 +09:00
Author
Owner

Progress update:

Completed commits:

  • 3210e84 Define stable workspace identity and metadata layout
  • 27067f3 Add bridge and helper crate skeletons
  • dee70e7 Define project entry and plugin metadata ownership

Completed in this issue:

  • initial mono-repo structure for Sublime, bridge, helper, docs/planning
  • stable workspace/cache identity and metadata split
  • settings model and .sublime-project vs plugin metadata boundary

Still open here:

  • minimum supported Sublime build decision
  • clearer documented metadata migration strategy
Progress update: Completed commits: - `3210e84` Define stable workspace identity and metadata layout - `27067f3` Add bridge and helper crate skeletons - `dee70e7` Define project entry and plugin metadata ownership Completed in this issue: - initial mono-repo structure for Sublime, bridge, helper, docs/planning - stable workspace/cache identity and metadata split - settings model and `.sublime-project` vs plugin metadata boundary Still open here: - minimum supported Sublime build decision - clearer documented metadata migration strategy
Author
Owner

Progress update:

Completed commit:

  • 7ef0e40 Add Linux CI for Python and Rust

Completed in this slice:

  • added Linux-only Gitea workflows for Python checks via uv
  • added Linux-only Gitea workflows for Rust fmt/clippy/test
  • documented that CI should mirror the local developer validation path

Still open here:

  • minimum supported Sublime build decision
  • clearer metadata migration strategy
Progress update: Completed commit: - `7ef0e40` Add Linux CI for Python and Rust Completed in this slice: - added Linux-only Gitea workflows for Python checks via `uv` - added Linux-only Gitea workflows for Rust fmt/clippy/test - documented that CI should mirror the local developer validation path Still open here: - minimum supported Sublime build decision - clearer metadata migration strategy
Author
Owner

Progress update:

Completed commits:

  • 5100c7c Tighten Python and Rust docstring rules
  • 6cc9d23 Normalize docs across Python and Rust boundaries

Completed in these slices:

  • tightened the repository-wide documentation rules for Python and Rust
  • updated existing Python public models and workflow boundaries to use attribute-oriented class docs and Google-style callable docs
  • expanded Rust crate docs with richer boundary explanations and runnable examples

Still open here:

  • minimum supported Sublime build decision
  • clearer metadata migration strategy
Progress update: Completed commits: - `5100c7c` Tighten Python and Rust docstring rules - `6cc9d23` Normalize docs across Python and Rust boundaries Completed in these slices: - tightened the repository-wide documentation rules for Python and Rust - updated existing Python public models and workflow boundaries to use attribute-oriented class docs and Google-style callable docs - expanded Rust crate docs with richer boundary explanations and runnable examples Still open here: - minimum supported Sublime build decision - clearer metadata migration strategy
Author
Owner

Progress update:

Completed commits:

  • 3308f25 Require evidence-backed checklist updates
  • e79b3a0 Cover and track Phase 0 edge-case checks

Completed in these slices:

  • made checklist updates evidence-driven by rule
  • added tests for same-root/different-alias identity separation
  • added tests for same-host/different-root identity separation
  • added tests for empty or aliasless SSH config parsing

Coverage note:

  • Phase 0 edge/test items backed by those tests are now checked
  • Phase 1-3 edge/test checklists remain open until their behaviors are implemented or explicitly tested
Progress update: Completed commits: - `3308f25` Require evidence-backed checklist updates - `e79b3a0` Cover and track Phase 0 edge-case checks Completed in these slices: - made checklist updates evidence-driven by rule - added tests for same-root/different-alias identity separation - added tests for same-host/different-root identity separation - added tests for empty or aliasless SSH config parsing Coverage note: - Phase 0 edge/test items backed by those tests are now checked - Phase 1-3 edge/test checklists remain open until their behaviors are implemented or explicitly tested
Author
Owner

Progress update:

Completed commit:

  • f65b540 Enforce 88-column Ruff docs checks

Completed in this slice:

  • set repository Ruff line length to 88
  • enabled Google-style docstring linting with D100, D101, D102, D103, and D417
  • kept pre-commit and CI aligned automatically by reusing the shared Ruff configuration

Rust note:

  • there is no comparable Clippy rule in the current toolchain that enforces example-rich crate docs, so Rust remains convention-driven there
Progress update: Completed commit: - `f65b540` Enforce 88-column Ruff docs checks Completed in this slice: - set repository Ruff line length to `88` - enabled Google-style docstring linting with `D100`, `D101`, `D102`, `D103`, and `D417` - kept pre-commit and CI aligned automatically by reusing the shared Ruff configuration Rust note: - there is no comparable Clippy rule in the current toolchain that enforces example-rich crate docs, so Rust remains convention-driven there
Author
Owner

Phase 0 foundation coverage is now complete.

Included commits:

  • dd5dc4a Align Python runtime with Sublime compatibility floor
  • 1c8f70b Track Phase 0 completion in planning

Validation run:

  • PRE_COMMIT_HOME=/home/mschoi/remote-ssh/sessions/.pre-commit-cache uv run pre-commit run --all-files

This closes the remaining Phase 0 items for runtime compatibility, metadata version handling, shared-cache fallback, and the outstanding edge-case checklist.

Phase 0 foundation coverage is now complete. Included commits: - `dd5dc4a` Align Python runtime with Sublime compatibility floor - `1c8f70b` Track Phase 0 completion in planning Validation run: - `PRE_COMMIT_HOME=/home/mschoi/remote-ssh/sessions/.pre-commit-cache uv run pre-commit run --all-files` This closes the remaining Phase 0 items for runtime compatibility, metadata version handling, shared-cache fallback, and the outstanding edge-case checklist.
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sublime-rs/sessions#2