Make project identity host-owned and add explicit project tags - #33
Draft
xai wants to merge 2 commits into
Draft
Conversation
Git-reported path casing can differ from canonical input casing on case-insensitive macOS filesystems, so those checkouts may receive a new hash even though benign checkouts retain their hash when path spelling matches. Signed-off-by: Olaf Lessenich <olessenich@eclipsesource.com>
Signed-off-by: Olaf Lessenich <olessenich@eclipsesource.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What it does
Closes #19.
The project namespace selects config, secrets, generated files, skills, caches,
network state, and cleanup scope. On
main, checkouts with a real.gitdirectory still asked Git for the path to hash. A crafted
commondircouldtherefore select another project's persisted state, and Git could report
different path casing on case-insensitive filesystems. Linked worktrees already
skipped that lookup and used their own paths, but there was no explicit way for
separate checkouts to share a namespace.
This PR makes the fallback namespace a hash of the canonical directory path and
adds an explicit host-side override:
~/.config/enclave/project-tags.jsonmaps exact canonical directories to anamed tag and shared namespace. The host-owned registry is never mounted into
a container and is rejected when malformed or unsafe.
enclave project tag set|unset|listandproject showexpose the workflow.Creating or joining a tag requires confirmation unless
--yesis used.Joining lists the complete shared scope;
--newand--existingpin intent.listandshowalso provide documented JSON output.Later members switch to it, leaving their previous data dormant. Tag
operations do not copy, merge, or delete project data, and the origin cannot
be removed while other members remain.
preferences now use the effective namespace. A backend-neutral lifetime
lease protects each writable config store; detached Docker sessions transfer
that lease to a host monitor, while a QEMU collision is rejected before store
preparation.
The worktree-specific config-store suffix and the Git worktree helper package
are removed. User documentation and architecture notes now describe tag
semantics and the JSON integration contract.
How to test
Follow-ups
CLI.
namespace, mounts, and labels they started with.
persistent sessions when a backend cannot select another store key.
Breaking changes
This PR introduces breaking changes and has been coordinated with maintainers.
Main-worktree checkouts whose Git-reported path spelling differs from the
canonical input path derive a new namespace on case-insensitive filesystems.
There is no migration. Linked worktrees and matching path spellings keep
their existing namespaces.
A second persistent QEMU session on the same config-store key now fails
instead of proceeding.
internal/theia:LoadPreferencesis replaced by the namespace-keyedLoadPreferencesForProject;Effective,GlobalPreferences, andProjectPreferencesare removed without replacements. Internal API only, noexternal contract.
Review checklist