Skip to content

Commit 933c8b6

Browse files
authored
feat!: v0.4.0 remove deprecated --profile flag (#6)
* refactor(v0.4.0): migrate tests to install_selection Switch the five test files that used init.run(profile_id=...) as a fixture setup to call install_selection(target, Selection(...)) instead. The legacy init.py shim is being removed in v0.4.0; this commit keeps the suite green so the deletion in the next commit can land cleanly. - test_init.py: rewrite as install_selection tests, drop the legacy --profile path coverage (test_legacy_profile_*, _unknown_profile_, _rejects_unsafe_profile_paths) and the contract-docs test (the v0.3.0 mapping for --profile generic is harnesses=[], which does not surface .solo-mise/generic/*). - test_doctor.py: drop init_mod import; install_selection now writes config.json so the openclaw-checks tests need 'openclaw' in the selection's harnesses. - test_ingest.py, test_handoff.py: swap init.run -> install_selection. - test_gitignore.py: pull GITIGNORE_BEGIN/END from install.py; drop the update_gitignore=False tests (install_selection always writes the managed block). 109 tests pass. * test(selection): drop legacy profile_to_selection coverage The 7 test_profile_to_selection_* cases exercise a function being removed in the next commit. Drop them and the now-unused import. Companion to cc26412 which migrated the other five test files off init.run. * feat(cli)!: remove deprecated --profile flag and supporting code The --profile flag was deprecated in v0.3.0 with a stderr warning showing the new --depth/--harnesses equivalent. v0.4.0 removes it along with the dead code paths it kept alive: - cli.py: drop the --profile argparse argument and the deprecation shim that translated profile ids into Selections. - selection.py: drop _PROFILE_MAP and profile_to_selection. - templates.py: drop load_profile (depth/harness/include manifests use _load_layered, which stays). - init.py: delete the module. install.install_selection is the only install path now. - templates/profiles/: delete the six legacy profile manifests. - prompt.py: drop the "(or --profile)" hint in the non-interactive error. BREAKING CHANGE: `solo-mise init --profile <x>` now errors out as an unrecognized argument. Use --depth + --harnesses (see v0.3.0 CHANGELOG migration table). * release: prepare v0.4.0 - Bump version to 0.4.0 in pyproject.toml and src/solo_mise/__init__.py. - CHANGELOG: document the --profile removal and link refs. - CI: drop the two legacy-profile install-from-source matrix entries (the flag no longer exists, so the jobs would just argparse-fail).
1 parent 7b283bd commit 933c8b6

21 files changed

Lines changed: 168 additions & 621 deletions

.github/workflows/ci.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -66,10 +66,6 @@ jobs:
6666
flags: "--depth workspace --harnesses none"
6767
- name: "repo+claude+publisher"
6868
flags: "--depth repo --harnesses claude --include publisher"
69-
- name: "legacy-workspace"
70-
flags: "--profile workspace"
71-
- name: "legacy-openclaw"
72-
flags: "--profile openclaw"
7369
steps:
7470
- uses: actions/checkout@v4
7571
- uses: actions/setup-python@v5

CHANGELOG.md

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,18 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [0.4.0] - 2026-05-17
9+
10+
### Removed
11+
- `solo-mise init --profile <x>` flag and all supporting code paths. The flag has been deprecated since v0.3.0 with a stderr warning showing the new equivalent. Anyone still using it must switch to `--depth ... --harnesses ...` (see the v0.3.0 migration table below).
12+
- Internal: `src/solo_mise/init.py` module (superseded by `install.install_selection`).
13+
- Internal: `templates/profiles/` directory and the six legacy profile manifests.
14+
- Internal: `templates.load_profile` and `selection.profile_to_selection`.
15+
16+
### Migration
17+
18+
Same as v0.3.0. If you somehow have v0.2.0-era scripts still using `--profile`, see the table in the v0.3.0 section below.
19+
820
## [0.3.0] - 2026-05-16
921

1022
### Added
@@ -91,7 +103,8 @@ Initial release.
91103
- OpenClaw adapter fragments and harness-aware doctor checks.
92104
- Experimental Hermes adapter fragments.
93105

94-
[Unreleased]: https://github.com/solomonneas/solo-mise/compare/v0.3.0...HEAD
106+
[Unreleased]: https://github.com/solomonneas/solo-mise/compare/v0.4.0...HEAD
107+
[0.4.0]: https://github.com/solomonneas/solo-mise/compare/v0.3.0...v0.4.0
95108
[0.3.0]: https://github.com/solomonneas/solo-mise/compare/v0.2.0...v0.3.0
96109
[0.2.0]: https://github.com/solomonneas/solo-mise/compare/v0.1.0...v0.2.0
97110
[0.1.0]: https://github.com/solomonneas/solo-mise/releases/tag/v0.1.0

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
44

55
[project]
66
name = "solo-mise"
7-
version = "0.3.0"
7+
version = "0.4.0"
88
description = "Mise en place for agent memory. Installable starter kit for a harness-agnostic agent workspace."
99
readme = "README.md"
1010
requires-python = ">=3.10"

src/solo_mise/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
"""Solomon's Mise en Place: installable starter kit for an agent kitchen."""
22

3-
__version__ = "0.3.0"
3+
__version__ = "0.4.0"

src/solo_mise/cli.py

Lines changed: 3 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -21,20 +21,8 @@ def _build_parser() -> argparse.ArgumentParser:
2121
sub.required = True
2222

2323
# init
24-
p_init = sub.add_parser("init", help="Materialize a profile into a target directory.")
24+
p_init = sub.add_parser("init", help="Materialize a selection into a target directory.")
2525
p_init.add_argument("--target", "-t", type=Path, default=Path("."), help="Where to install.")
26-
p_init.add_argument(
27-
"--profile",
28-
"-p",
29-
default=None,
30-
choices=["repo", "workspace", "openclaw", "hermes", "generic", "publisher"],
31-
help="(Deprecated) Profile to install. Use --depth/--harnesses instead.",
32-
)
33-
p_init.add_argument(
34-
"--harness",
35-
help="Override the memory-owner label rendered into bootstrap files. "
36-
"Defaults to the profile's memory_owner_default.",
37-
)
3826
p_init.add_argument("--force", action="store_true", help="Overwrite existing files.")
3927
p_init.add_argument(
4028
"--allow-home",
@@ -54,7 +42,7 @@ def _build_parser() -> argparse.ArgumentParser:
5442
choices=["repo", "workspace"],
5543
default=None,
5644
help="Install depth: 'repo' (minimal) or 'workspace' (full home). "
57-
"Required unless --profile is used.",
45+
"Omit for an interactive prompt.",
5846
)
5947
p_init.add_argument(
6048
"--harnesses",
@@ -176,30 +164,7 @@ def main(argv=None) -> int:
176164
allow_home=getattr(args, "allow_home", False),
177165
)
178166

179-
# Legacy --profile path: translate to a Selection, warn, install.
180-
if args.profile:
181-
from .selection import profile_to_selection
182-
from .install import install_selection
183-
sel = profile_to_selection(args.profile)
184-
equivalent = f"--depth {sel.depth} --harnesses {','.join(sel.harnesses) or 'none'}"
185-
if sel.owner != "this-repo" and sel.owner in sel.harnesses:
186-
equivalent += f" --owner {sel.owner}"
187-
for inc in sel.includes:
188-
equivalent += f" --include {inc}"
189-
print(
190-
f"warning: --profile is deprecated. The v0.3.0+ equivalent is "
191-
f"`{equivalent}`. --profile will be removed in v0.4.0.",
192-
file=sys.stderr,
193-
)
194-
return install_selection(
195-
target=args.target,
196-
selection=sel,
197-
force=getattr(args, "force", False),
198-
dry_run=getattr(args, "dry_run", False),
199-
allow_home=getattr(args, "allow_home", False),
200-
)
201-
202-
# No flags and no --profile: interactive prompt.
167+
# No selection flags: interactive prompt.
203168
from .prompt import NonInteractiveError
204169
from .install import install_selection
205170
try:

src/solo_mise/init.py

Lines changed: 0 additions & 223 deletions
This file was deleted.

src/solo_mise/prompt.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ def prompt_for_selection() -> Selection:
4646
if not sys.stdin.isatty():
4747
raise NonInteractiveError(
4848
"solo-mise init needs a TTY for the interactive prompt. "
49-
"Pass --depth and --harnesses (or --profile) for scripting."
49+
"Pass --depth and --harnesses for scripting."
5050
)
5151

5252
selected_harnesses = _toggle_prompt(

src/solo_mise/selection.py

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -64,29 +64,3 @@ def resolve_owner(harnesses: List[str], override: Optional[str] = None) -> str:
6464
if candidate in harnesses:
6565
return candidate
6666
return "this-repo"
67-
68-
69-
_PROFILE_MAP = {
70-
"repo": Selection(depth="repo", harnesses=["claude"], owner="claude", includes=[]),
71-
"workspace": Selection(depth="workspace", harnesses=["claude"], owner="claude", includes=[]),
72-
"openclaw": Selection(depth="workspace", harnesses=["claude", "openclaw"], owner="openclaw", includes=[]),
73-
"hermes": Selection(depth="workspace", harnesses=["claude", "hermes"], owner="hermes", includes=[]),
74-
"generic": Selection(depth="workspace", harnesses=[], owner="this-repo", includes=[]),
75-
"publisher": Selection(depth="repo", harnesses=["claude"], owner="claude", includes=["publisher"]),
76-
}
77-
78-
79-
def profile_to_selection(profile_id: str) -> Selection:
80-
"""Translate a legacy --profile id into a Selection. Used by the deprecation shim."""
81-
if profile_id not in _PROFILE_MAP:
82-
raise ValueError(
83-
f"unknown profile: {profile_id!r} (valid: {sorted(_PROFILE_MAP)})"
84-
)
85-
sel = _PROFILE_MAP[profile_id]
86-
# Return a copy to keep callers from mutating the map.
87-
return Selection(
88-
depth=sel.depth,
89-
harnesses=list(sel.harnesses),
90-
owner=sel.owner,
91-
includes=list(sel.includes),
92-
)

0 commit comments

Comments
 (0)