runtime-sdk 0.4.33__tar.gz → 0.4.34__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.
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/PKG-INFO +1 -1
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/pyproject.toml +1 -1
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk/cli.py +35 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk.egg-info/PKG-INFO +1 -1
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/README.md +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk/__init__.py +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk/client.py +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk/config.py +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk.egg-info/SOURCES.txt +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk.egg-info/dependency_links.txt +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk.egg-info/entry_points.txt +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk.egg-info/requires.txt +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/scripts/runtime_sdk.egg-info/top_level.txt +0 -0
- {runtime_sdk-0.4.33 → runtime_sdk-0.4.34}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: runtime-sdk
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.34
|
|
4
4
|
Summary: Runtime Python SDK and CLI
|
|
5
5
|
Project-URL: Repository, https://github.com/The-Money-Company-Limited/runtimevm
|
|
6
6
|
Project-URL: Issues, https://github.com/The-Money-Company-Limited/runtimevm/issues
|
|
@@ -1068,6 +1068,36 @@ def _computer_url_label(c: dict[str, Any]) -> str:
|
|
|
1068
1068
|
|
|
1069
1069
|
|
|
1070
1070
|
|
|
1071
|
+
def _computer_email_address(c: dict[str, Any]) -> str:
|
|
1072
|
+
explicit = str(c.get("email_address") or "").strip()
|
|
1073
|
+
if explicit:
|
|
1074
|
+
return explicit
|
|
1075
|
+
slug = str(c.get("slug") or "").strip()
|
|
1076
|
+
public_url = str(c.get("public_url") or "").strip()
|
|
1077
|
+
if not slug or not public_url:
|
|
1078
|
+
return ""
|
|
1079
|
+
host = urlparse(public_url).netloc
|
|
1080
|
+
if not host:
|
|
1081
|
+
return ""
|
|
1082
|
+
suffix = host.removeprefix(slug + ".")
|
|
1083
|
+
if suffix == host or not suffix:
|
|
1084
|
+
return ""
|
|
1085
|
+
return f"{slug}@mail.{suffix}"
|
|
1086
|
+
|
|
1087
|
+
|
|
1088
|
+
|
|
1089
|
+
def _with_computer_email(payload: dict[str, Any]) -> dict[str, Any]:
|
|
1090
|
+
if payload.get("email_address"):
|
|
1091
|
+
return payload
|
|
1092
|
+
email_address = _computer_email_address(payload)
|
|
1093
|
+
if not email_address:
|
|
1094
|
+
return payload
|
|
1095
|
+
enriched = dict(payload)
|
|
1096
|
+
enriched["email_address"] = email_address
|
|
1097
|
+
return enriched
|
|
1098
|
+
|
|
1099
|
+
|
|
1100
|
+
|
|
1071
1101
|
def _relative_time_label(value: Any) -> str:
|
|
1072
1102
|
raw = str(value or "").strip()
|
|
1073
1103
|
if not raw:
|
|
@@ -1282,6 +1312,7 @@ def _render_computer_panel(c: dict[str, Any], *, title: str = "computer") -> Non
|
|
|
1282
1312
|
("state", f"{_computer_status_dot(status)} {status}", status_style),
|
|
1283
1313
|
("share", str(c.get("visibility") or "public"), "bold white"),
|
|
1284
1314
|
("url", _computer_url_label(c) or "—", "white"),
|
|
1315
|
+
("email", _computer_email_address(c) or "—", "white"),
|
|
1285
1316
|
("age", _computer_created_label(c) or "—", "dim"),
|
|
1286
1317
|
("id", str(c.get("id") or "—"), "dim"),
|
|
1287
1318
|
]
|
|
@@ -2118,10 +2149,14 @@ def handle_create(
|
|
|
2118
2149
|
|
|
2119
2150
|
def render(payload: dict[str, Any]) -> None:
|
|
2120
2151
|
_render_computer_panel(payload, title="created")
|
|
2152
|
+
email_address = payload.get("email_address") or _computer_email_address(payload)
|
|
2153
|
+
if email_address:
|
|
2154
|
+
_UI.console().print(f"[bold green]@[/bold green] [cyan]{email_address}[/cyan]")
|
|
2121
2155
|
url = payload.get("public_url")
|
|
2122
2156
|
if url:
|
|
2123
2157
|
_UI.console().print(f"[bold green]→[/bold green] [cyan]{url}[/cyan]")
|
|
2124
2158
|
|
|
2159
|
+
result = _with_computer_email(result)
|
|
2125
2160
|
code = report_success(result, render)
|
|
2126
2161
|
if code != 0 or not _interactive():
|
|
2127
2162
|
return code
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: runtime-sdk
|
|
3
|
-
Version: 0.4.
|
|
3
|
+
Version: 0.4.34
|
|
4
4
|
Summary: Runtime Python SDK and CLI
|
|
5
5
|
Project-URL: Repository, https://github.com/The-Money-Company-Limited/runtimevm
|
|
6
6
|
Project-URL: Issues, https://github.com/The-Money-Company-Limited/runtimevm/issues
|
|
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
|