worktree-runtime 0.1.0__cp310-abi3-win_amd64.whl
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.
- _worktree_runtime_rust/__init__.py +5 -0
- _worktree_runtime_rust/_worktree_runtime_rust.pyd +0 -0
- worktree_runtime/AGENTS.md +21 -0
- worktree_runtime/SURFACE.yaml +247 -0
- worktree_runtime/__init__.py +1 -0
- worktree_runtime/api/__init__.py +129 -0
- worktree_runtime/api/__init__.pyi +356 -0
- worktree_runtime/presentation/__init__.py +1 -0
- worktree_runtime/presentation/audit_cli.py +91 -0
- worktree_runtime/py.typed +1 -0
- worktree_runtime-0.1.0.dist-info/METADATA +127 -0
- worktree_runtime-0.1.0.dist-info/RECORD +16 -0
- worktree_runtime-0.1.0.dist-info/WHEEL +4 -0
- worktree_runtime-0.1.0.dist-info/entry_points.txt +2 -0
- worktree_runtime-0.1.0.dist-info/licenses/LICENSE +21 -0
- worktree_runtime-0.1.0.dist-info/sboms/worktree_runtime_pyo3.cyclonedx.json +3159 -0
|
Binary file
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
# src/worktree_runtime
|
|
2
|
+
|
|
3
|
+
This tree is the Python facade. Rust (`_worktree_runtime_rust`) is the only
|
|
4
|
+
implementation: `api/__init__.py` re-exports it and a missing native module
|
|
5
|
+
is an `ImportError`. Never add a silent Python fallback.
|
|
6
|
+
|
|
7
|
+
Allowed in this tree:
|
|
8
|
+
|
|
9
|
+
- `__init__.py`, `py.typed`, `AGENTS.md`
|
|
10
|
+
- `api/__init__.py` (re-export + `__all__`) and `api/__init__.pyi` (stub)
|
|
11
|
+
- `SURFACE.yaml` (public surface manifest incl. `console_scripts`)
|
|
12
|
+
- `presentation/__init__.py`, `presentation/audit_cli.py` (argparse shim
|
|
13
|
+
over `worktree_runtime.api`; exit codes are frozen in `SURFACE.yaml` and
|
|
14
|
+
`tests/cli`)
|
|
15
|
+
|
|
16
|
+
Do not implement behavior in new Python modules. Do not add `domain/`,
|
|
17
|
+
`application/`, or `infrastructure/`. Do not add files beyond this facade.
|
|
18
|
+
|
|
19
|
+
If the public surface changes, update `SURFACE.yaml` and `api/__init__.pyi`
|
|
20
|
+
in the same change; `mypy.stubtest` and `tests/contract/test_stub_signatures.py`
|
|
21
|
+
compare the stub with the runtime.
|
|
@@ -0,0 +1,247 @@
|
|
|
1
|
+
version: 2
|
|
2
|
+
description: worktree_runtime public API surface manifest
|
|
3
|
+
enforced: true
|
|
4
|
+
modules:
|
|
5
|
+
root:
|
|
6
|
+
import_path: worktree_runtime.api
|
|
7
|
+
source_file: src/worktree_runtime/api/__init__.py
|
|
8
|
+
symbols:
|
|
9
|
+
- name: ADAPTIVE_TASK_SHARED_DIR_ENV
|
|
10
|
+
source: _worktree_runtime_rust
|
|
11
|
+
kind: constant
|
|
12
|
+
added_in_wave: issue-1982
|
|
13
|
+
- name: AuditRecord
|
|
14
|
+
source: _worktree_runtime_rust
|
|
15
|
+
kind: class
|
|
16
|
+
added_in_wave: contract-holes
|
|
17
|
+
- name: AUDIT_INVOKERS
|
|
18
|
+
source: _worktree_runtime_rust
|
|
19
|
+
kind: constant
|
|
20
|
+
added_in_wave: leftover-deferred
|
|
21
|
+
- name: AUDIT_KINDS
|
|
22
|
+
source: _worktree_runtime_rust
|
|
23
|
+
kind: constant
|
|
24
|
+
added_in_wave: leftover-deferred
|
|
25
|
+
- name: AUDIT_OUTCOMES
|
|
26
|
+
source: _worktree_runtime_rust
|
|
27
|
+
kind: constant
|
|
28
|
+
added_in_wave: leftover-deferred
|
|
29
|
+
- name: GitHubPolicy
|
|
30
|
+
source: _worktree_runtime_rust
|
|
31
|
+
kind: class
|
|
32
|
+
added_in_wave: rust-primary
|
|
33
|
+
- name: GitWorktree
|
|
34
|
+
source: _worktree_runtime_rust
|
|
35
|
+
kind: class
|
|
36
|
+
added_in_wave: git-domain-vocabulary
|
|
37
|
+
- name: ProjectIdInvalidError
|
|
38
|
+
source: _worktree_runtime_rust
|
|
39
|
+
kind: class
|
|
40
|
+
added_in_wave: rust-primary
|
|
41
|
+
- name: BindingValidationOptions
|
|
42
|
+
source: _worktree_runtime_rust
|
|
43
|
+
kind: class
|
|
44
|
+
added_in_wave: 1
|
|
45
|
+
- name: BindingValidationResult
|
|
46
|
+
source: _worktree_runtime_rust
|
|
47
|
+
kind: class
|
|
48
|
+
added_in_wave: 1
|
|
49
|
+
- name: CURRENT_SCHEMA_VERSION
|
|
50
|
+
source: _worktree_runtime_rust
|
|
51
|
+
kind: constant
|
|
52
|
+
added_in_wave: 1
|
|
53
|
+
- name: LEGACY_PROJECT_ID
|
|
54
|
+
source: _worktree_runtime_rust
|
|
55
|
+
kind: constant
|
|
56
|
+
added_in_wave: 1
|
|
57
|
+
- name: MAIN_BRANCHES
|
|
58
|
+
source: _worktree_runtime_rust
|
|
59
|
+
kind: constant
|
|
60
|
+
added_in_wave: 1
|
|
61
|
+
- name: NOVELER_BRANCH_ENV
|
|
62
|
+
source: _worktree_runtime_rust
|
|
63
|
+
kind: constant
|
|
64
|
+
added_in_wave: 1
|
|
65
|
+
- name: NOVELER_PROJECT_ROOT_ENV
|
|
66
|
+
source: _worktree_runtime_rust
|
|
67
|
+
kind: constant
|
|
68
|
+
added_in_wave: 1
|
|
69
|
+
- name: NOVELER_REPO_ROOT_ENV
|
|
70
|
+
source: _worktree_runtime_rust
|
|
71
|
+
kind: constant
|
|
72
|
+
added_in_wave: 1
|
|
73
|
+
- name: NOVELER_SHARED_DIR_ENV
|
|
74
|
+
source: _worktree_runtime_rust
|
|
75
|
+
kind: constant
|
|
76
|
+
added_in_wave: 1
|
|
77
|
+
- name: NOVELER_STATE_DIR_ENV
|
|
78
|
+
source: _worktree_runtime_rust
|
|
79
|
+
kind: constant
|
|
80
|
+
added_in_wave: 1
|
|
81
|
+
- name: NOVELER_WORKTREE_BASE_ENV
|
|
82
|
+
source: _worktree_runtime_rust
|
|
83
|
+
kind: constant
|
|
84
|
+
added_in_wave: 1
|
|
85
|
+
- name: NOVELER_WORKTREE_ENV
|
|
86
|
+
source: _worktree_runtime_rust
|
|
87
|
+
kind: constant
|
|
88
|
+
added_in_wave: 1
|
|
89
|
+
- name: UV_PROJECT_ENV
|
|
90
|
+
source: _worktree_runtime_rust
|
|
91
|
+
kind: constant
|
|
92
|
+
added_in_wave: 1
|
|
93
|
+
- name: WORKTREE_IDENTITY_ENV_VARS
|
|
94
|
+
source: _worktree_runtime_rust
|
|
95
|
+
kind: constant
|
|
96
|
+
added_in_wave: 1
|
|
97
|
+
- name: WORKTREE_LOCATION_ENV_VARS
|
|
98
|
+
source: _worktree_runtime_rust
|
|
99
|
+
kind: constant
|
|
100
|
+
added_in_wave: 1
|
|
101
|
+
- name: WORKTREE_PROJECT_ENV_VARS
|
|
102
|
+
source: _worktree_runtime_rust
|
|
103
|
+
kind: constant
|
|
104
|
+
added_in_wave: 1
|
|
105
|
+
- name: WORKTREE_RUNTIME_ENV_VARS
|
|
106
|
+
source: _worktree_runtime_rust
|
|
107
|
+
kind: constant
|
|
108
|
+
added_in_wave: 1
|
|
109
|
+
- name: WorktreeBinding
|
|
110
|
+
source: _worktree_runtime_rust
|
|
111
|
+
kind: class
|
|
112
|
+
added_in_wave: 1
|
|
113
|
+
- name: WorktreeBindingStore
|
|
114
|
+
source: _worktree_runtime_rust
|
|
115
|
+
kind: class
|
|
116
|
+
added_in_wave: 1
|
|
117
|
+
- name: WorktreeListEntry
|
|
118
|
+
source: _worktree_runtime_rust
|
|
119
|
+
kind: class
|
|
120
|
+
added_in_wave: issue-2231
|
|
121
|
+
- name: WorktreeListError
|
|
122
|
+
source: _worktree_runtime_rust
|
|
123
|
+
kind: class
|
|
124
|
+
added_in_wave: issue-2231
|
|
125
|
+
- name: WorktreePreconditionResult
|
|
126
|
+
source: _worktree_runtime_rust
|
|
127
|
+
kind: class
|
|
128
|
+
added_in_wave: 1
|
|
129
|
+
- name: is_main_worktree
|
|
130
|
+
source: _worktree_runtime_rust
|
|
131
|
+
kind: function
|
|
132
|
+
added_in_wave: git-domain-vocabulary
|
|
133
|
+
- name: list_worktrees
|
|
134
|
+
source: _worktree_runtime_rust
|
|
135
|
+
kind: function
|
|
136
|
+
added_in_wave: issue-2231
|
|
137
|
+
- name: list_bindings
|
|
138
|
+
source: _worktree_runtime_rust
|
|
139
|
+
kind: function
|
|
140
|
+
added_in_wave: binding-forget
|
|
141
|
+
- name: load_binding
|
|
142
|
+
source: _worktree_runtime_rust
|
|
143
|
+
kind: function
|
|
144
|
+
added_in_wave: 1
|
|
145
|
+
- name: normalize_path
|
|
146
|
+
source: _worktree_runtime_rust
|
|
147
|
+
kind: function
|
|
148
|
+
added_in_wave: 1
|
|
149
|
+
- name: path_fingerprint
|
|
150
|
+
source: _worktree_runtime_rust
|
|
151
|
+
kind: function
|
|
152
|
+
added_in_wave: git-domain-vocabulary
|
|
153
|
+
- name: read_records
|
|
154
|
+
source: _worktree_runtime_rust
|
|
155
|
+
kind: function
|
|
156
|
+
added_in_wave: 1
|
|
157
|
+
- name: reap_rotation_sentinel
|
|
158
|
+
source: _worktree_runtime_rust
|
|
159
|
+
kind: function
|
|
160
|
+
added_in_wave: 1
|
|
161
|
+
- name: record_event
|
|
162
|
+
source: _worktree_runtime_rust
|
|
163
|
+
kind: function
|
|
164
|
+
added_in_wave: 1
|
|
165
|
+
- name: recover_binding
|
|
166
|
+
source: _worktree_runtime_rust
|
|
167
|
+
kind: function
|
|
168
|
+
added_in_wave: 1
|
|
169
|
+
- name: remove_binding
|
|
170
|
+
source: _worktree_runtime_rust
|
|
171
|
+
kind: function
|
|
172
|
+
added_in_wave: binding-forget
|
|
173
|
+
- name: register_binding
|
|
174
|
+
source: _worktree_runtime_rust
|
|
175
|
+
kind: function
|
|
176
|
+
added_in_wave: 1
|
|
177
|
+
- name: resolve_git_worktree
|
|
178
|
+
source: _worktree_runtime_rust
|
|
179
|
+
kind: function
|
|
180
|
+
added_in_wave: git-domain-vocabulary
|
|
181
|
+
- name: resolve_github_policy
|
|
182
|
+
source: _worktree_runtime_rust
|
|
183
|
+
kind: function
|
|
184
|
+
added_in_wave: rust-primary
|
|
185
|
+
- name: resolve_main_branches
|
|
186
|
+
source: _worktree_runtime_rust
|
|
187
|
+
kind: function
|
|
188
|
+
added_in_wave: rust-primary
|
|
189
|
+
- name: resolve_known_worktree_bases
|
|
190
|
+
source: _worktree_runtime_rust
|
|
191
|
+
kind: function
|
|
192
|
+
added_in_wave: 1
|
|
193
|
+
- name: resolve_project_id
|
|
194
|
+
source: _worktree_runtime_rust
|
|
195
|
+
kind: function
|
|
196
|
+
added_in_wave: 1
|
|
197
|
+
- name: resolve_state_dir_name
|
|
198
|
+
source: _worktree_runtime_rust
|
|
199
|
+
kind: function
|
|
200
|
+
added_in_wave: 1
|
|
201
|
+
- name: resolve_worktree_base
|
|
202
|
+
source: _worktree_runtime_rust
|
|
203
|
+
kind: function
|
|
204
|
+
added_in_wave: 1
|
|
205
|
+
- name: resolve_worktree_dir
|
|
206
|
+
source: _worktree_runtime_rust
|
|
207
|
+
kind: function
|
|
208
|
+
added_in_wave: 1
|
|
209
|
+
- name: set_noveler_project_root_for_worktree
|
|
210
|
+
source: _worktree_runtime_rust
|
|
211
|
+
kind: function
|
|
212
|
+
added_in_wave: 1
|
|
213
|
+
- name: state_dir
|
|
214
|
+
source: _worktree_runtime_rust
|
|
215
|
+
kind: function
|
|
216
|
+
added_in_wave: 1
|
|
217
|
+
- name: store_relative_path
|
|
218
|
+
source: _worktree_runtime_rust
|
|
219
|
+
kind: function
|
|
220
|
+
added_in_wave: 1
|
|
221
|
+
- name: validate_binding
|
|
222
|
+
source: _worktree_runtime_rust
|
|
223
|
+
kind: function
|
|
224
|
+
added_in_wave: 1
|
|
225
|
+
- name: validate_current_binding
|
|
226
|
+
source: _worktree_runtime_rust
|
|
227
|
+
kind: function
|
|
228
|
+
added_in_wave: git-domain-vocabulary
|
|
229
|
+
- name: validate_main_worktree
|
|
230
|
+
source: _worktree_runtime_rust
|
|
231
|
+
kind: function
|
|
232
|
+
added_in_wave: git-domain-vocabulary
|
|
233
|
+
- name: worktree_identity_env_vars
|
|
234
|
+
source: _worktree_runtime_rust
|
|
235
|
+
kind: function
|
|
236
|
+
added_in_wave: 1
|
|
237
|
+
- name: worktree_runtime_env_vars
|
|
238
|
+
source: _worktree_runtime_rust
|
|
239
|
+
kind: function
|
|
240
|
+
added_in_wave: 1
|
|
241
|
+
console_scripts:
|
|
242
|
+
- name: worktree-runtime-audit
|
|
243
|
+
entry_point: worktree_runtime.presentation.audit_cli:main
|
|
244
|
+
exit_codes:
|
|
245
|
+
0: record written
|
|
246
|
+
2: usage error (argparse), including malformed --extra JSON
|
|
247
|
+
3: record could not be written (WORKTREE_AUDIT_WRITE_FAILED) or record_event raised
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Worktree runtime package (Rust-primary)."""
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
"""Public worktree path and binding API.
|
|
2
|
+
|
|
3
|
+
Rust is the implementation SSOT. This module re-exports the PyO3 extension
|
|
4
|
+
``_worktree_runtime_rust``. A missing native module is a hard install error.
|
|
5
|
+
"""
|
|
6
|
+
|
|
7
|
+
from __future__ import annotations
|
|
8
|
+
|
|
9
|
+
from _worktree_runtime_rust import ( # type: ignore[import-not-found]
|
|
10
|
+
ADAPTIVE_TASK_SHARED_DIR_ENV,
|
|
11
|
+
AUDIT_INVOKERS,
|
|
12
|
+
AUDIT_KINDS,
|
|
13
|
+
AUDIT_OUTCOMES,
|
|
14
|
+
CURRENT_SCHEMA_VERSION,
|
|
15
|
+
AuditRecord,
|
|
16
|
+
GitHubPolicy,
|
|
17
|
+
GitWorktree,
|
|
18
|
+
LEGACY_PROJECT_ID,
|
|
19
|
+
MAIN_BRANCHES,
|
|
20
|
+
NOVELER_BRANCH_ENV,
|
|
21
|
+
NOVELER_PROJECT_ROOT_ENV,
|
|
22
|
+
NOVELER_REPO_ROOT_ENV,
|
|
23
|
+
NOVELER_SHARED_DIR_ENV,
|
|
24
|
+
NOVELER_STATE_DIR_ENV,
|
|
25
|
+
NOVELER_WORKTREE_BASE_ENV,
|
|
26
|
+
NOVELER_WORKTREE_ENV,
|
|
27
|
+
ProjectIdInvalidError,
|
|
28
|
+
BindingValidationOptions,
|
|
29
|
+
BindingValidationResult,
|
|
30
|
+
WorktreeBinding,
|
|
31
|
+
WorktreeBindingStore,
|
|
32
|
+
WorktreePreconditionResult,
|
|
33
|
+
UV_PROJECT_ENV,
|
|
34
|
+
WORKTREE_IDENTITY_ENV_VARS,
|
|
35
|
+
WORKTREE_LOCATION_ENV_VARS,
|
|
36
|
+
WORKTREE_PROJECT_ENV_VARS,
|
|
37
|
+
WORKTREE_RUNTIME_ENV_VARS,
|
|
38
|
+
WorktreeListEntry,
|
|
39
|
+
WorktreeListError,
|
|
40
|
+
is_main_worktree,
|
|
41
|
+
list_bindings,
|
|
42
|
+
list_worktrees,
|
|
43
|
+
load_binding,
|
|
44
|
+
normalize_path,
|
|
45
|
+
path_fingerprint,
|
|
46
|
+
read_records,
|
|
47
|
+
reap_rotation_sentinel,
|
|
48
|
+
record_event,
|
|
49
|
+
recover_binding,
|
|
50
|
+
register_binding,
|
|
51
|
+
remove_binding,
|
|
52
|
+
resolve_git_worktree,
|
|
53
|
+
resolve_github_policy,
|
|
54
|
+
resolve_known_worktree_bases,
|
|
55
|
+
resolve_main_branches,
|
|
56
|
+
resolve_project_id,
|
|
57
|
+
resolve_state_dir_name,
|
|
58
|
+
resolve_worktree_base,
|
|
59
|
+
resolve_worktree_dir,
|
|
60
|
+
set_noveler_project_root_for_worktree,
|
|
61
|
+
state_dir,
|
|
62
|
+
store_relative_path,
|
|
63
|
+
validate_binding,
|
|
64
|
+
validate_current_binding,
|
|
65
|
+
validate_main_worktree,
|
|
66
|
+
worktree_identity_env_vars,
|
|
67
|
+
worktree_runtime_env_vars,
|
|
68
|
+
)
|
|
69
|
+
|
|
70
|
+
__all__ = [
|
|
71
|
+
"ADAPTIVE_TASK_SHARED_DIR_ENV",
|
|
72
|
+
"AUDIT_INVOKERS",
|
|
73
|
+
"AUDIT_KINDS",
|
|
74
|
+
"AUDIT_OUTCOMES",
|
|
75
|
+
"AuditRecord",
|
|
76
|
+
"CURRENT_SCHEMA_VERSION",
|
|
77
|
+
"GitHubPolicy",
|
|
78
|
+
"GitWorktree",
|
|
79
|
+
"LEGACY_PROJECT_ID",
|
|
80
|
+
"MAIN_BRANCHES",
|
|
81
|
+
"BindingValidationOptions",
|
|
82
|
+
"BindingValidationResult",
|
|
83
|
+
"NOVELER_BRANCH_ENV",
|
|
84
|
+
"NOVELER_PROJECT_ROOT_ENV",
|
|
85
|
+
"NOVELER_REPO_ROOT_ENV",
|
|
86
|
+
"NOVELER_SHARED_DIR_ENV",
|
|
87
|
+
"NOVELER_STATE_DIR_ENV",
|
|
88
|
+
"NOVELER_WORKTREE_BASE_ENV",
|
|
89
|
+
"NOVELER_WORKTREE_ENV",
|
|
90
|
+
"ProjectIdInvalidError",
|
|
91
|
+
"WorktreeBinding",
|
|
92
|
+
"WorktreeBindingStore",
|
|
93
|
+
"WorktreeListEntry",
|
|
94
|
+
"WorktreeListError",
|
|
95
|
+
"WorktreePreconditionResult",
|
|
96
|
+
"UV_PROJECT_ENV",
|
|
97
|
+
"WORKTREE_IDENTITY_ENV_VARS",
|
|
98
|
+
"WORKTREE_LOCATION_ENV_VARS",
|
|
99
|
+
"WORKTREE_PROJECT_ENV_VARS",
|
|
100
|
+
"WORKTREE_RUNTIME_ENV_VARS",
|
|
101
|
+
"is_main_worktree",
|
|
102
|
+
"list_bindings",
|
|
103
|
+
"list_worktrees",
|
|
104
|
+
"load_binding",
|
|
105
|
+
"normalize_path",
|
|
106
|
+
"path_fingerprint",
|
|
107
|
+
"recover_binding",
|
|
108
|
+
"read_records",
|
|
109
|
+
"reap_rotation_sentinel",
|
|
110
|
+
"record_event",
|
|
111
|
+
"register_binding",
|
|
112
|
+
"remove_binding",
|
|
113
|
+
"resolve_git_worktree",
|
|
114
|
+
"resolve_github_policy",
|
|
115
|
+
"resolve_known_worktree_bases",
|
|
116
|
+
"resolve_main_branches",
|
|
117
|
+
"resolve_project_id",
|
|
118
|
+
"resolve_state_dir_name",
|
|
119
|
+
"resolve_worktree_base",
|
|
120
|
+
"resolve_worktree_dir",
|
|
121
|
+
"set_noveler_project_root_for_worktree",
|
|
122
|
+
"state_dir",
|
|
123
|
+
"store_relative_path",
|
|
124
|
+
"validate_binding",
|
|
125
|
+
"validate_current_binding",
|
|
126
|
+
"validate_main_worktree",
|
|
127
|
+
"worktree_identity_env_vars",
|
|
128
|
+
"worktree_runtime_env_vars",
|
|
129
|
+
]
|