optio-codex 0.2.0__tar.gz → 0.2.1__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.
- {optio_codex-0.2.0 → optio_codex-0.2.1}/PKG-INFO +1 -1
- {optio_codex-0.2.0 → optio_codex-0.2.1}/pyproject.toml +1 -1
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/__init__.py +2 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/conversation.py +2 -1
- optio_codex-0.2.1/src/optio_codex/info.py +7 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/session.py +5 -4
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex.egg-info/PKG-INFO +1 -1
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex.egg-info/SOURCES.txt +2 -0
- optio_codex-0.2.1/tests/test_agent_info.py +15 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/README.md +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/setup.cfg +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/conversation_listener.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/cred_watcher.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/fs_allowlist.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/host_actions.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/models.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/prompt.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/seed_manifest.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/snapshots.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/types.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex/verify.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex.egg-info/dependency_links.txt +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex.egg-info/requires.txt +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/src/optio_codex.egg-info/top_level.txt +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_await_codex_gone.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_codex_cache.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_config.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_config_hooks.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_conversation.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_conversation_controls.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_conversation_listener.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_cred_watcher.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_file_download.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_file_upload.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_fs_allowlist.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_host_actions.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_import.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_input_wiring.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_kill_ttyd_by_socket.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_models.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_prompt.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_real_codex_conversation.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_real_codex_seed_resume.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_real_codex_session.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_sandbox_enforce.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_seed_manifest.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_session_conversation.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_session_lease.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_session_local.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_session_remote.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_session_resume.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_session_sandbox.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_session_seed.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_snapshots.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_teardown_session_tree.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_verify.py +0 -0
- {optio_codex-0.2.0 → optio_codex-0.2.1}/tests/test_workdir_trust.py +0 -0
|
@@ -9,6 +9,7 @@ from optio_host import (
|
|
|
9
9
|
SSHConfig,
|
|
10
10
|
)
|
|
11
11
|
|
|
12
|
+
from optio_codex.info import AGENT_INFO
|
|
12
13
|
from optio_codex.seed_manifest import (
|
|
13
14
|
CODEX_CRED_MANIFEST,
|
|
14
15
|
CODEX_SEED_MANIFEST,
|
|
@@ -38,6 +39,7 @@ _logging.getLogger("asyncssh").setLevel(_logging.WARNING)
|
|
|
38
39
|
|
|
39
40
|
|
|
40
41
|
__all__ = [
|
|
42
|
+
"AGENT_INFO",
|
|
41
43
|
"create_codex_task",
|
|
42
44
|
"run_codex_session",
|
|
43
45
|
"AllowedDir",
|
|
@@ -101,6 +101,7 @@ from optio_agents.conversation import (
|
|
|
101
101
|
PermissionRequest,
|
|
102
102
|
)
|
|
103
103
|
from optio_codex import models as codex_models
|
|
104
|
+
from optio_codex.info import AGENT_INFO
|
|
104
105
|
|
|
105
106
|
_LOG = logging.getLogger(__name__)
|
|
106
107
|
|
|
@@ -120,7 +121,7 @@ class CodexConversation:
|
|
|
120
121
|
self,
|
|
121
122
|
*,
|
|
122
123
|
cwd: str,
|
|
123
|
-
agent_label: str =
|
|
124
|
+
agent_label: str = AGENT_INFO.slug,
|
|
124
125
|
permission_gate: bool = False,
|
|
125
126
|
model: str | None = None,
|
|
126
127
|
reasoning_effort: str | None = None,
|
|
@@ -24,6 +24,7 @@ from optio_host.paths import task_dir
|
|
|
24
24
|
|
|
25
25
|
from optio_codex import cred_watcher, host_actions
|
|
26
26
|
from optio_codex import models as codex_models
|
|
27
|
+
from optio_codex.info import AGENT_INFO
|
|
27
28
|
from optio_codex.conversation import CodexConversation
|
|
28
29
|
from optio_codex.conversation_listener import ConversationListener
|
|
29
30
|
from optio_codex.fs_allowlist import (
|
|
@@ -290,7 +291,7 @@ async def run_codex_session(ctx: ProcessContext, config: CodexTaskConfig) -> Non
|
|
|
290
291
|
**(config.env or {}),
|
|
291
292
|
**(hook_ctx.browser_launch_env or {}),
|
|
292
293
|
}
|
|
293
|
-
ctx.report_progress(None, "Launching
|
|
294
|
+
ctx.report_progress(None, f"Launching {AGENT_INFO.name}…")
|
|
294
295
|
handle, tmux_path_local, ttyd_port, tmux_socket, tmux_session = await host_actions.launch_ttyd_with_codex(
|
|
295
296
|
host,
|
|
296
297
|
ttyd_path=ttyd_path,
|
|
@@ -309,7 +310,7 @@ async def run_codex_session(ctx: ProcessContext, config: CodexTaskConfig) -> Non
|
|
|
309
310
|
await ctx.set_widget_data({
|
|
310
311
|
"iframeSrc": "{widgetProxyUrl}/",
|
|
311
312
|
})
|
|
312
|
-
ctx.report_progress(None, "
|
|
313
|
+
ctx.report_progress(None, f"{AGENT_INFO.name} is live")
|
|
313
314
|
|
|
314
315
|
# iframe-input widget: start the engine-side input listener and publish it
|
|
315
316
|
# as the control upstream. The operator types messages / drives TUI menus
|
|
@@ -383,7 +384,7 @@ async def run_codex_session(ctx: ProcessContext, config: CodexTaskConfig) -> Non
|
|
|
383
384
|
**(config.env or {}),
|
|
384
385
|
**(hook_ctx.browser_launch_env or {}),
|
|
385
386
|
}
|
|
386
|
-
ctx.report_progress(None, "Launching
|
|
387
|
+
ctx.report_progress(None, f"Launching {AGENT_INFO.name} (conversation)…")
|
|
387
388
|
handle = await host.launch_subprocess(
|
|
388
389
|
cmd, env=env, cwd=host.workdir,
|
|
389
390
|
env_remove=config.scrub_env, stdin=True, merge_stderr=False,
|
|
@@ -398,7 +399,7 @@ async def run_codex_session(ctx: ProcessContext, config: CodexTaskConfig) -> Non
|
|
|
398
399
|
raise
|
|
399
400
|
|
|
400
401
|
ctx.publish_result(conversation)
|
|
401
|
-
ctx.report_progress(None, "
|
|
402
|
+
ctx.report_progress(None, f"{AGENT_INFO.name} conversation is live")
|
|
402
403
|
|
|
403
404
|
# Opt-in dashboard chat widget: per-task SSE listener over the
|
|
404
405
|
# published conversation, reached via the widget proxy (which injects
|
|
@@ -6,6 +6,7 @@ src/optio_codex/conversation_listener.py
|
|
|
6
6
|
src/optio_codex/cred_watcher.py
|
|
7
7
|
src/optio_codex/fs_allowlist.py
|
|
8
8
|
src/optio_codex/host_actions.py
|
|
9
|
+
src/optio_codex/info.py
|
|
9
10
|
src/optio_codex/models.py
|
|
10
11
|
src/optio_codex/prompt.py
|
|
11
12
|
src/optio_codex/seed_manifest.py
|
|
@@ -18,6 +19,7 @@ src/optio_codex.egg-info/SOURCES.txt
|
|
|
18
19
|
src/optio_codex.egg-info/dependency_links.txt
|
|
19
20
|
src/optio_codex.egg-info/requires.txt
|
|
20
21
|
src/optio_codex.egg-info/top_level.txt
|
|
22
|
+
tests/test_agent_info.py
|
|
21
23
|
tests/test_await_codex_gone.py
|
|
22
24
|
tests/test_codex_cache.py
|
|
23
25
|
tests/test_config.py
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
from optio_codex import AGENT_INFO
|
|
2
|
+
from optio_codex.types import CodexTaskConfig
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
def test_agent_info_values():
|
|
6
|
+
assert AGENT_INFO.slug == "codex"
|
|
7
|
+
assert AGENT_INFO.name == "Codex"
|
|
8
|
+
assert AGENT_INFO.url == "https://openai.com/codex"
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
def test_agent_info_slug_matches_agent_type():
|
|
12
|
+
import dataclasses
|
|
13
|
+
|
|
14
|
+
fields = {f.name: f for f in dataclasses.fields(CodexTaskConfig)}
|
|
15
|
+
assert fields["agent_type"].default == AGENT_INFO.slug
|
|
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
|
|
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
|
|
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
|
|
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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|