delphi-team 0.1.0__py3-none-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.
- delphi_team/__init__.py +7 -0
- delphi_team/__main__.py +3 -0
- delphi_team/_shim.py +78 -0
- delphi_team/bin/.gitkeep +0 -0
- delphi_team/bin/delphi.exe +4 -0
- delphi_team-0.1.0.dist-info/METADATA +31 -0
- delphi_team-0.1.0.dist-info/RECORD +9 -0
- delphi_team-0.1.0.dist-info/WHEEL +4 -0
- delphi_team-0.1.0.dist-info/entry_points.txt +3 -0
delphi_team/__init__.py
ADDED
delphi_team/__main__.py
ADDED
delphi_team/_shim.py
ADDED
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
"""Hand argv, stdin, stdout, stderr and the exit code to the bundled delphi binary.
|
|
2
|
+
|
|
3
|
+
On POSIX the process is replaced outright, so streams and signals are inherited and the
|
|
4
|
+
exit code is the binary's own. Windows has no real ``execv``, so the binary is run as a
|
|
5
|
+
child and its return code is propagated.
|
|
6
|
+
|
|
7
|
+
There is deliberately no fallback to ``npx`` (ADR-0005): it would reintroduce a Node
|
|
8
|
+
requirement for exactly the pip and uv users these wheels exist to serve. A platform with
|
|
9
|
+
no binary gets a clear message instead of a silent download.
|
|
10
|
+
"""
|
|
11
|
+
|
|
12
|
+
import os
|
|
13
|
+
import subprocess
|
|
14
|
+
import sys
|
|
15
|
+
from pathlib import Path
|
|
16
|
+
|
|
17
|
+
_BIN_DIR = Path(__file__).resolve().parent / "bin"
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
def binary_path() -> Path:
|
|
21
|
+
"""Where the compiled CLI lives inside the installed wheel."""
|
|
22
|
+
return _BIN_DIR / ("delphi.exe" if os.name == "nt" else "delphi")
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
def _machine() -> str:
|
|
26
|
+
if hasattr(os, "uname"):
|
|
27
|
+
return os.uname().machine
|
|
28
|
+
return os.environ.get("PROCESSOR_ARCHITECTURE", "unknown")
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
def _missing_binary_message(exe: Path) -> str:
|
|
32
|
+
return (
|
|
33
|
+
f"delphi-team has no compiled binary for this platform "
|
|
34
|
+
f"({sys.platform}, {_machine()}).\n"
|
|
35
|
+
f"Expected it at: {exe}\n\n"
|
|
36
|
+
"Install the Node distribution instead:\n"
|
|
37
|
+
" npm install -g delphi-team\n\n"
|
|
38
|
+
"If you believe this platform should be supported, please open an issue."
|
|
39
|
+
)
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
def _unrunnable_binary_message(exe: Path, error: OSError) -> str:
|
|
43
|
+
return (
|
|
44
|
+
f"delphi-team found its binary but could not run it: {error}\n"
|
|
45
|
+
f" {exe}\n\n"
|
|
46
|
+
"The file is usually not executable, or the install is incomplete. Try reinstalling:\n"
|
|
47
|
+
" pipx reinstall delphi-team\n\n"
|
|
48
|
+
"Or use the Node distribution instead:\n"
|
|
49
|
+
" npm install -g delphi-team"
|
|
50
|
+
)
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
def _fail(message: str) -> "NoReturn": # noqa: F821 - quoted so Python 3.9 needs no import
|
|
54
|
+
sys.stderr.write(message + "\n")
|
|
55
|
+
raise SystemExit(1)
|
|
56
|
+
|
|
57
|
+
|
|
58
|
+
def main() -> None:
|
|
59
|
+
exe = binary_path()
|
|
60
|
+
if not exe.is_file():
|
|
61
|
+
_fail(_missing_binary_message(exe))
|
|
62
|
+
|
|
63
|
+
args = [str(exe), *sys.argv[1:]]
|
|
64
|
+
try:
|
|
65
|
+
if os.name == "nt":
|
|
66
|
+
# Windows has no execv that replaces the process, so run the binary as a child.
|
|
67
|
+
raise SystemExit(subprocess.run(args).returncode)
|
|
68
|
+
sys.stdout.flush()
|
|
69
|
+
sys.stderr.flush()
|
|
70
|
+
os.execv(str(exe), args)
|
|
71
|
+
except KeyboardInterrupt:
|
|
72
|
+
# On Windows the console delivers Ctrl+C to both processes; without this the child
|
|
73
|
+
# exits cleanly and the parent then dies with a traceback. 130 is the shell convention.
|
|
74
|
+
raise SystemExit(130) from None
|
|
75
|
+
except OSError as error:
|
|
76
|
+
# A present but unrunnable binary: no execute bit, wrong architecture, truncated file.
|
|
77
|
+
# Report it the way the missing case is reported rather than raising a traceback.
|
|
78
|
+
_fail(_unrunnable_binary_message(exe, error))
|
delphi_team/bin/.gitkeep
ADDED
|
File without changes
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: delphi-team
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Run Claude Code as a department. Unofficial; works with Claude Code.
|
|
5
|
+
License-Expression: MIT
|
|
6
|
+
Keywords: agents,claude-code,cli,orchestration
|
|
7
|
+
Classifier: Environment :: Console
|
|
8
|
+
Classifier: Intended Audience :: Developers
|
|
9
|
+
Classifier: Operating System :: MacOS
|
|
10
|
+
Classifier: Operating System :: Microsoft :: Windows
|
|
11
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
12
|
+
Classifier: Programming Language :: Python :: 3
|
|
13
|
+
Requires-Python: >=3.9
|
|
14
|
+
Description-Content-Type: text/markdown
|
|
15
|
+
|
|
16
|
+
# delphi-team (Python distribution)
|
|
17
|
+
|
|
18
|
+
Run Claude Code as a department. Unofficial; works with Claude Code.
|
|
19
|
+
|
|
20
|
+
This wheel carries a compiled binary of the `delphi` CLI, so nothing here needs Node.
|
|
21
|
+
All logic lives in the TypeScript core — this package is a shim that hands over argv,
|
|
22
|
+
stdio and the exit code. See the project README for what the tool does.
|
|
23
|
+
|
|
24
|
+
```
|
|
25
|
+
pipx install delphi-team
|
|
26
|
+
uvx delphi-team --help
|
|
27
|
+
pip install delphi-team
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
Platforms without a published binary fail with an instruction to use `npm install -g delphi-team`
|
|
31
|
+
rather than silently downloading a Node runtime.
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
delphi_team/__init__.py,sha256=1zu6TfHlpjnikf-cDP3N5Z7K9_MHeHM-L83tXO8fouE,233
|
|
2
|
+
delphi_team/__main__.py,sha256=F1MCG7dHzZ12k97abzU1d4DDs-aH_snuNvVrbLBQWeU,43
|
|
3
|
+
delphi_team/_shim.py,sha256=93wNLk1LxDa1s7wODTHg3mtAZ8Th7SgX6ZigljmhUIs,2898
|
|
4
|
+
delphi_team/bin/.gitkeep,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
5
|
+
delphi_team/bin/delphi.exe,sha256=7q_GDqPmpTFM2gEFeZh1aJjKqr870pIRm9s4frpYWmc,87333888
|
|
6
|
+
delphi_team-0.1.0.dist-info/METADATA,sha256=28rb212APvdRRTPhfk17DE4dhEoOX6VEpxr_KITbsgQ,1115
|
|
7
|
+
delphi_team-0.1.0.dist-info/WHEEL,sha256=0nQjyt02uAQbhbYKWZzlDb_ZXUmJUwgypQJ-m16yWKo,94
|
|
8
|
+
delphi_team-0.1.0.dist-info/entry_points.txt,sha256=a3mLl_7Xxdbk_J2pQQ0C_ZpblOAYC_28vCR69E0xBiY,87
|
|
9
|
+
delphi_team-0.1.0.dist-info/RECORD,,
|