wbcli 0.1.2__tar.gz → 0.1.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {wbcli-0.1.2 → wbcli-0.1.3}/PKG-INFO +1 -1
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_agents.py +1 -1
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_session_metadata.py +6 -6
- {wbcli-0.1.2 → wbcli-0.1.3}/wbcli.egg-info/PKG-INFO +1 -1
- wbcli-0.1.3/wbcli.egg-info/scm_version.json +8 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/_version.py +3 -3
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/session_metadata.py +11 -23
- wbcli-0.1.2/wbcli.egg-info/scm_version.json +0 -8
- {wbcli-0.1.2 → wbcli-0.1.3}/.gitattributes +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.github/CODEOWNERS +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.github/actions/update-homebrew-tap/action.yml +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.github/aw/actions-lock.json +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.github/workflows/ci.yml +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.github/workflows/release.yml +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.github/workflows/sync-docs.lock.yml +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.github/workflows/sync-docs.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.github/workflows/update-homebrew-tap.yml +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.gitignore +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/.pre-commit-config.yaml +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/CONTRIBUTING.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/Formula/workbench.rb +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/LICENSE +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/README.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/docs/design/model-selection.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/docs/img/workbench-logo.png +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/pyproject.toml +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/setup.cfg +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/__init__.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/conftest.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_adapters.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_cli.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_conventions.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_directives.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_docs.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_final_review.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_github_pr.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_headroom.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_layout_migration.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_orchestrator.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_path_resolver.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_pipeline.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_plan_parser.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_pr_writer.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_profile.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_prompt_builder.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_session_status.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_standalone_runners.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_tmux.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/tests/test_worktree.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/uv.lock +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/wbcli.egg-info/SOURCES.txt +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/wbcli.egg-info/dependency_links.txt +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/wbcli.egg-info/entry_points.txt +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/wbcli.egg-info/requires.txt +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/wbcli.egg-info/scm_file_list.json +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/wbcli.egg-info/top_level.txt +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/__init__.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/adapters.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/agents.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/cli.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/conventions.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/__init__.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/branch_fixer.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/branch_reviewer.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/branch_reviewer_followup.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/fixer.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/implementor.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/merger.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/planner.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/pr_writer.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/requirements_summarizer.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/reviewer.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/reviewer_followup.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/tdd_implementor.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/tdd_tester.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directive_texts/tester.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/directives.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/final_review.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/github_pr.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/headroom.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/orchestrator.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/path_resolver.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/plan_parser.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/pr_writer.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/profile.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/session_status.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/skills/__init__.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/skills/configure-workbench/SKILL.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/skills/generate-conventions/SKILL.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/skills/install-workbench/SKILL.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/skills/plan-workbench/SKILL.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/skills/use-workbench/SKILL.md +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/tmux.py +0 -0
- {wbcli-0.1.2 → wbcli-0.1.3}/workbench/worktree.py +0 -0
|
@@ -719,7 +719,7 @@ class TestSessionMetadataWiring:
|
|
|
719
719
|
assert env["WB_PLAN"] == "p"
|
|
720
720
|
assert env["WB_TASK"] == "task-1"
|
|
721
721
|
assert env["WB_AGENT"] == Role.IMPLEMENTOR.value
|
|
722
|
-
assert "OTEL_RESOURCE_ATTRIBUTES" in env
|
|
722
|
+
assert "OTEL_RESOURCE_ATTRIBUTES" not in env
|
|
723
723
|
|
|
724
724
|
def test_run_agent_trace_prompt_prepends_block(self, sample_ctx, tmp_path):
|
|
725
725
|
"""trace_prompt=True → build_command receives prompt starting with the block."""
|
|
@@ -49,11 +49,11 @@ class TestAsEnv:
|
|
|
49
49
|
"WB_TASK": "task-3",
|
|
50
50
|
"WB_AGENT": "tester",
|
|
51
51
|
"WB_STEP": "test#1",
|
|
52
|
-
"OTEL_RESOURCE_ATTRIBUTES": (
|
|
53
|
-
"wb.plan=p,wb.wave=2,wb.task=task-3,wb.agent=tester,wb.step=test#1"
|
|
54
|
-
),
|
|
55
52
|
}
|
|
56
53
|
|
|
54
|
+
def test_no_otel_resource_attributes(self, meta_full):
|
|
55
|
+
assert "OTEL_RESOURCE_ATTRIBUTES" not in meta_full.as_env()
|
|
56
|
+
|
|
57
57
|
def test_empty_metadata(self):
|
|
58
58
|
assert SessionMetadata().as_env() == {}
|
|
59
59
|
|
|
@@ -79,11 +79,11 @@ class TestMergeTraceEnv:
|
|
|
79
79
|
assert merged["WB_TASK"] == "task-3"
|
|
80
80
|
assert merged["WB_AGENT"] == "tester"
|
|
81
81
|
assert merged["WB_STEP"] == "test#1"
|
|
82
|
-
assert "OTEL_RESOURCE_ATTRIBUTES" in merged
|
|
82
|
+
assert "OTEL_RESOURCE_ATTRIBUTES" not in merged
|
|
83
83
|
|
|
84
|
-
def
|
|
84
|
+
def test_preexisting_otel_resource_attributes_untouched(self, meta_full):
|
|
85
85
|
merged = merge_trace_env({"OTEL_RESOURCE_ATTRIBUTES": "service.name=foo"}, meta_full)
|
|
86
|
-
assert merged["OTEL_RESOURCE_ATTRIBUTES"]
|
|
86
|
+
assert merged["OTEL_RESOURCE_ATTRIBUTES"] == "service.name=foo"
|
|
87
87
|
|
|
88
88
|
def test_none_returns_base_copy(self):
|
|
89
89
|
assert merge_trace_env({"A": "1"}, None) == {"A": "1"}
|
|
@@ -18,7 +18,7 @@ version_tuple: tuple[int | str, ...]
|
|
|
18
18
|
commit_id: str | None
|
|
19
19
|
__commit_id__: str | None
|
|
20
20
|
|
|
21
|
-
__version__ = version = '0.1.
|
|
22
|
-
__version_tuple__ = version_tuple = (0, 1,
|
|
21
|
+
__version__ = version = '0.1.3'
|
|
22
|
+
__version_tuple__ = version_tuple = (0, 1, 3)
|
|
23
23
|
|
|
24
|
-
__commit_id__ = commit_id = '
|
|
24
|
+
__commit_id__ = commit_id = 'g86ca6933b'
|
|
@@ -49,17 +49,14 @@ class SessionMetadata:
|
|
|
49
49
|
return "```wb-session\n" + "\n".join(lines) + "\n```"
|
|
50
50
|
|
|
51
51
|
def as_env(self) -> dict[str, str]:
|
|
52
|
-
"""WB_* vars for non-empty fields
|
|
52
|
+
"""WB_* vars for non-empty fields, e.g. {"WB_PLAN": "p", "WB_WAVE": "2"}.
|
|
53
53
|
|
|
54
|
-
Returns {} when no fields are set.
|
|
55
|
-
OTEL_RESOURCE_ATTRIBUTES
|
|
54
|
+
Returns {} when no fields are set. Claude Code overwrites
|
|
55
|
+
OTEL_RESOURCE_ATTRIBUTES on its own spans, so run metadata rides on
|
|
56
|
+
WB_* env vars instead; a tracing backend (thirdeye) reads those and
|
|
57
|
+
records them as span tags.
|
|
56
58
|
"""
|
|
57
|
-
|
|
58
|
-
if not fields:
|
|
59
|
-
return {}
|
|
60
|
-
env = {f"WB_{key.upper()}": value for key, value in fields}
|
|
61
|
-
env["OTEL_RESOURCE_ATTRIBUTES"] = ",".join(f"wb.{key}={value}" for key, value in fields)
|
|
62
|
-
return env
|
|
59
|
+
return {f"WB_{key.upper()}": value for key, value in self._fields()}
|
|
63
60
|
|
|
64
61
|
|
|
65
62
|
def with_session_metadata(prompt: str, meta: SessionMetadata | None) -> str:
|
|
@@ -72,21 +69,12 @@ def with_session_metadata(prompt: str, meta: SessionMetadata | None) -> str:
|
|
|
72
69
|
|
|
73
70
|
|
|
74
71
|
def merge_trace_env(base: Mapping[str, str], meta: SessionMetadata | None) -> dict[str, str]:
|
|
75
|
-
"""Overlay meta.as_env() onto a copy of base.
|
|
72
|
+
"""Overlay meta.as_env() (WB_* vars) onto a copy of base.
|
|
76
73
|
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
base resource attributes survive. Returns dict(base) unchanged when meta is
|
|
80
|
-
None or empty.
|
|
74
|
+
Returns dict(base) unchanged when meta is None or renders empty. Any
|
|
75
|
+
OTEL_* vars already in base pass through untouched.
|
|
81
76
|
"""
|
|
82
77
|
merged = dict(base)
|
|
83
|
-
if meta is None:
|
|
84
|
-
|
|
85
|
-
extra = meta.as_env()
|
|
86
|
-
inherited_otel = merged.get("OTEL_RESOURCE_ATTRIBUTES", "")
|
|
87
|
-
for key, value in extra.items():
|
|
88
|
-
if key == "OTEL_RESOURCE_ATTRIBUTES" and inherited_otel:
|
|
89
|
-
merged[key] = f"{inherited_otel},{value}"
|
|
90
|
-
else:
|
|
91
|
-
merged[key] = value
|
|
78
|
+
if meta is not None:
|
|
79
|
+
merged.update(meta.as_env())
|
|
92
80
|
return merged
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|