You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix review issues: package-private internals, update stale docs
Make UvRunner and PythonProbe package-private — they are internal
implementation details used by PythonEnv, not part of the public API.
Update api-contracts.md to match the actual implemented API (remove
unimplemented load/importModule/PythonSource, show real PythonEngine,
PythonEnv, HostFunction, and @ScriptInterface usage).
Update implementation-plan.md to mark Phases 1-3 as done.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The `bundled()` mode extracts `pyproject.toml` and `uv.lock` from JAR resources, bootstraps CPython and dependencies on first run via uv, and caches the environment locally for subsequent runs.
104
-
105
116
## Low-level escape hatch
106
117
107
-
The low-level API is optional and secondary:
118
+
The low-level API is available for tests, diagnostics, and simple scripts:
108
119
109
120
```java
110
-
publicinterfacePythonSession {
111
-
voidexec(Stringcode);
112
-
Objecteval(Stringexpression);
121
+
try (var engine =PythonEngine.create(env)) {
122
+
engine.exec("print('hello')");
123
+
int count = engine.invokeFunction("my_module", "count", List.of("hello world"), int.class);
113
124
}
114
125
```
115
-
116
-
This is useful for tests, diagnostics, and simple scripts, but documentation should lead with Java contracts.
0 commit comments