Remove GitHub-specific project plumbing
This commit is contained in:
parent
895cb608c0
commit
0181de2563
7 changed files with 13 additions and 62 deletions
|
|
@ -298,7 +298,7 @@ def _build_parser() -> argparse.ArgumentParser:
|
|||
"""
|
||||
Examples:
|
||||
pyro run debian:12 -- git --version
|
||||
pyro run debian:12 --network -- git ls-remote https://github.com/octocat/Hello-World.git
|
||||
pyro run debian:12 --network -- python3 -c "import urllib.request as u; print(u.urlopen('https://example.com').status)"
|
||||
|
||||
The guest command output and the [run] summary are written to different
|
||||
streams, so they may appear in either order. Use --json for a deterministic
|
||||
|
|
|
|||
|
|
@ -23,11 +23,10 @@ __all__ = ["Pyro", "run_ollama_tool_demo"]
|
|||
DEFAULT_OLLAMA_BASE_URL: Final[str] = "http://localhost:11434/v1"
|
||||
DEFAULT_OLLAMA_MODEL: Final[str] = "llama3.2:3b"
|
||||
MAX_TOOL_ROUNDS: Final[int] = 12
|
||||
CLONE_TARGET_DIR: Final[str] = "hello-world"
|
||||
NETWORK_PROOF_COMMAND: Final[str] = (
|
||||
"rm -rf hello-world "
|
||||
"&& git clone --depth 1 https://github.com/octocat/Hello-World.git hello-world >/dev/null "
|
||||
"&& git -C hello-world rev-parse --is-inside-work-tree"
|
||||
'python3 -c "import urllib.request as u; '
|
||||
"print(u.urlopen('https://example.com').status)"
|
||||
'"'
|
||||
)
|
||||
|
||||
TOOL_SPECS: Final[list[dict[str, Any]]] = [
|
||||
|
|
|
|||
|
|
@ -9,9 +9,9 @@ from pathlib import Path
|
|||
from pyro_mcp.api import Pyro
|
||||
|
||||
NETWORK_CHECK_COMMAND = (
|
||||
"rm -rf hello-world "
|
||||
"&& git clone --depth 1 https://github.com/octocat/Hello-World.git hello-world >/dev/null "
|
||||
"&& git -C hello-world rev-parse --is-inside-work-tree"
|
||||
'python3 -c "import urllib.request as u; '
|
||||
"print(u.urlopen('https://example.com').status)"
|
||||
'"'
|
||||
)
|
||||
|
||||
|
||||
|
|
@ -76,7 +76,7 @@ def main() -> None: # pragma: no cover - CLI wiring
|
|||
print(f"[network] execution_mode={result.execution_mode}")
|
||||
print(f"[network] network_enabled={result.network_enabled}")
|
||||
print(f"[network] exit_code={result.exit_code}")
|
||||
if result.exit_code == 0 and result.stdout.strip() == "true":
|
||||
if result.exit_code == 0 and result.stdout.strip() == "200":
|
||||
print("[network] result=success")
|
||||
return
|
||||
print("[network] result=failure")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue