Skip to content

Commit b6d6098

Browse files
committed
chore(release): bump version to 0.2.10
1 parent b5e9d98 commit b6d6098

6 files changed

Lines changed: 369 additions & 73 deletions

File tree

Makefile

Lines changed: 68 additions & 60 deletions
Original file line numberDiff line numberDiff line change
@@ -112,82 +112,90 @@ wheelhouse-linux: wheelhouse-clean
112112
@mkdir -p $(WHEELHOUSE)
113113
# manylinux x86_64 (quay.io/pypa) — ABI3: build once with Python 3.12
114114
docker run --rm --platform linux/amd64 -v "$(PWD)":/io $(MANYLINUX_X86) \
115-
bash -lc 'set -e; \
116-
yum -y install curl perl-core >/dev/null 2>&1 || true; \
117-
(perl -MText::Template -e1 >/dev/null 2>&1 || (curl -sL https://cpanmin.us | perl - App::cpanminus Text::Template >/dev/null)); \
118-
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && \
119-
. $$HOME/.cargo/env && \
120-
P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
121-
$$P -m pip install -U pip maturin && \
122-
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
115+
bash -lc 'set -e; \
116+
yum -y install curl perl-core >/dev/null 2>&1 || true; \
117+
(perl -MText::Template -e1 >/dev/null 2>&1 || (curl -sL https://cpanmin.us | perl - App::cpanminus Text::Template >/dev/null)); \
118+
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && \
119+
. $$HOME/.cargo/env && \
120+
P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
121+
$$P -m pip install -U pip maturin && \
122+
export CFLAGS="$$CFLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE"; \
123+
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
123124
# manylinux aarch64 (quay.io/pypa) — ABI3: build once with Python 3.12
124125
docker run --rm --platform linux/arm64 -v "$(PWD)":/io $(MANYLINUX_ARM) \
125-
bash -lc 'set -e; \
126-
yum -y install curl perl-core >/dev/null 2>&1 || true; \
127-
(perl -MText::Template -e1 >/dev/null 2>&1 || (curl -sL https://cpanmin.us | perl - App::cpanminus Text::Template >/dev/null)); \
128-
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && \
129-
. $$HOME/.cargo/env && \
130-
P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
131-
$$P -m pip install -U pip maturin && \
132-
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
126+
bash -lc 'set -e; \
127+
yum -y install curl perl-core >/dev/null 2>&1 || true; \
128+
(perl -MText::Template -e1 >/dev/null 2>&1 || (curl -sL https://cpanmin.us | perl - App::cpanminus Text::Template >/dev/null)); \
129+
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && \
130+
. $$HOME/.cargo/env && \
131+
P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
132+
$$P -m pip install -U pip maturin && \
133+
export CFLAGS="$$CFLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE"; \
134+
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
133135
# musllinux (Alpine) x86_64 (quay.io/pypa) — ABI3
134136
docker run --rm --platform linux/amd64 -v "$(PWD)":/io $(MUSLLINUX_X86) \
135-
bash -lc 'set -e; \
136-
apk add --no-cache curl perl perl-text-template >/dev/null 2>&1 || true; \
137-
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && \
138-
. $$HOME/.cargo/env && \
139-
P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
140-
$$P -m pip install -U pip maturin && \
141-
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -m /io/crates/codex_native/Cargo.toml -i $$P --compatibility musllinux_1_2 -o /io/$(WHEELHOUSE)'
137+
bash -lc 'set -e; \
138+
apk add --no-cache curl perl perl-text-template >/dev/null 2>&1 || true; \
139+
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && \
140+
. $$HOME/.cargo/env && \
141+
P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
142+
$$P -m pip install -U pip maturin && \
143+
export CFLAGS="$$CFLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE"; \
144+
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -m /io/crates/codex_native/Cargo.toml -i $$P --compatibility musllinux_1_2 -o /io/$(WHEELHOUSE)'
142145
# musllinux (Alpine) aarch64 (quay.io/pypa) — ABI3
143146
docker run --rm --platform linux/arm64 -v "$(PWD)":/io $(MUSLLINUX_ARM) \
144-
bash -lc 'set -e; \
145-
apk add --no-cache curl perl perl-text-template >/dev/null 2>&1 || true; \
146-
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && \
147-
. $$HOME/.cargo/env && \
148-
P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
149-
$$P -m pip install -U pip maturin && \
150-
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -m /io/crates/codex_native/Cargo.toml -i $$P --compatibility musllinux_1_2 -o /io/$(WHEELHOUSE)'
147+
bash -lc 'set -e; \
148+
apk add --no-cache curl perl perl-text-template >/dev/null 2>&1 || true; \
149+
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal && \
150+
. $$HOME/.cargo/env && \
151+
P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
152+
$$P -m pip install -U pip maturin && \
153+
export CFLAGS="$$CFLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE"; \
154+
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -m /io/crates/codex_native/Cargo.toml -i $$P --compatibility musllinux_1_2 -o /io/$(WHEELHOUSE)'
151155
@echo "Wheelhouse contents:" && ls -al $(WHEELHOUSE)
152156

153157
# Build only manylinux x86_64 (useful to avoid cross-arch emulation)
154-
wheelhouse-linux-amd64: wheelhouse-clean
155-
@mkdir -p $(WHEELHOUSE)
158+
wheelhouse-linux-amd64: wheelhouse-clean
159+
@mkdir -p $(WHEELHOUSE)
156160
docker run --rm --platform linux/amd64 -v "$(PWD)":/io $(MANYLINUX_X86) \
157-
bash -lc 'set -e; yum -y install curl perl-core >/dev/null 2>&1 || true; \
158-
(perl -MText::Template -e1 >/dev/null 2>&1 || (curl -sL https://cpanmin.us | perl - App::cpanminus Text::Template >/dev/null)); \
159-
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal; \
160-
. $$HOME/.cargo/env; P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
161-
$$P -m pip install -U pip maturin; \
162-
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -j $$(( $$(nproc) )) -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
161+
bash -lc 'set -e; yum -y install curl perl-core >/dev/null 2>&1 || true; \
162+
(perl -MText::Template -e1 >/dev/null 2>&1 || (curl -sL https://cpanmin.us | perl - App::cpanminus Text::Template >/dev/null)); \
163+
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal; \
164+
. $$HOME/.cargo/env; P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
165+
$$P -m pip install -U pip maturin; \
166+
export CFLAGS="$$CFLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE"; \
167+
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -j $$(( $$(nproc) )) -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
163168

164169
# Build only manylinux aarch64 (fast on Apple Silicon; slow on x86_64)
165-
wheelhouse-linux-arm64: wheelhouse-clean
166-
@mkdir -p $(WHEELHOUSE)
170+
wheelhouse-linux-arm64: wheelhouse-clean
171+
@mkdir -p $(WHEELHOUSE)
167172
docker run --rm --platform linux/arm64 -v "$(PWD)":/io $(MANYLINUX_ARM) \
168-
bash -lc 'set -e; yum -y install curl perl-core >/dev/null 2>&1 || true; \
169-
(perl -MText::Template -e1 >/dev/null 2>&1 || (curl -sL https://cpanmin.us | perl - App::cpanminus Text::Template >/dev/null)); \
170-
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal; \
171-
. $$HOME/.cargo/env; P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
172-
$$P -m pip install -U pip maturin; \
173-
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -j $$(( $$(nproc) )) -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
173+
bash -lc 'set -e; yum -y install curl perl-core >/dev/null 2>&1 || true; \
174+
(perl -MText::Template -e1 >/dev/null 2>&1 || (curl -sL https://cpanmin.us | perl - App::cpanminus Text::Template >/dev/null)); \
175+
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal; \
176+
. $$HOME/.cargo/env; P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
177+
$$P -m pip install -U pip maturin; \
178+
export CFLAGS="$$CFLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE"; \
179+
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release -j $$(( $$(nproc) )) -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
174180

175181
# Build only musllinux x86_64 (Alpine)
176-
wheelhouse-musl-amd64: wheelhouse-clean
177-
@mkdir -p $(WHEELHOUSE)
182+
wheelhouse-musl-amd64: wheelhouse-clean
183+
@mkdir -p $(WHEELHOUSE)
178184
docker run --rm --platform linux/amd64 -v "$(PWD)":/io $(MUSLLINUX_X86) \
179-
bash -lc 'set -e; apk add --no-cache curl perl perl-text-template >/dev/null 2>&1 || true; \
180-
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal; \
181-
. $$HOME/.cargo/env; P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
182-
$$P -m pip install -U pip maturin; \
183-
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release --compatibility musllinux_1_2 -j $$(( $$(nproc) )) -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
185+
bash -lc 'set -e; apk add --no-cache curl perl perl-text-template >/dev/null 2>&1 || true; \
186+
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal; \
187+
. $$HOME/.cargo/env; P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
188+
$$P -m pip install -U pip maturin; \
189+
export CFLAGS="$$CFLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE"; \
190+
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release --compatibility musllinux_1_2 -j $$(( $$(nproc) )) -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
184191

185192
# Build only musllinux aarch64 (Alpine)
186-
wheelhouse-musl-arm64: wheelhouse-clean
187-
@mkdir -p $(WHEELHOUSE)
193+
wheelhouse-musl-arm64: wheelhouse-clean
194+
@mkdir -p $(WHEELHOUSE)
188195
docker run --rm --platform linux/arm64 -v "$(PWD)":/io $(MUSLLINUX_ARM) \
189-
bash -lc 'set -e; apk add --no-cache curl perl perl-text-template >/dev/null 2>&1 || true; \
190-
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal; \
191-
. $$HOME/.cargo/env; P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
192-
$$P -m pip install -U pip maturin; \
193-
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release --compatibility musllinux_1_2 -j $$(( $$(nproc) )) -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'
196+
bash -lc 'set -e; apk add --no-cache curl perl perl-text-template >/dev/null 2>&1 || true; \
197+
curl -sSf https://sh.rustup.rs | sh -s -- -y --profile minimal; \
198+
. $$HOME/.cargo/env; P=$$(ls -1 /opt/python/cp312*/bin/python | head -n1); \
199+
$$P -m pip install -U pip maturin; \
200+
export CFLAGS="$$CFLAGS -D_DEFAULT_SOURCE -D_BSD_SOURCE"; \
201+
PATH=$$HOME/.cargo/bin:$$PATH $$P -m maturin build --release --compatibility musllinux_1_2 -j $$(( $$(nproc) )) -m /io/crates/codex_native/Cargo.toml -i $$P -o /io/$(WHEELHOUSE)'

codex/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,4 @@
3131
]
3232

3333
# Package version. Kept in sync with Cargo.toml via CI before builds.
34-
__version__ = "0.2.9"
34+
__version__ = "0.2.10"

codex/config.py

Lines changed: 162 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
from enum import Enum
44
from typing import Any, cast
55

6-
from pydantic import BaseModel, ConfigDict, Field
6+
from pydantic import AliasChoices, BaseModel, ConfigDict, Field
77

88

99
class ApprovalPolicy(str, Enum):
@@ -36,6 +36,126 @@ class SandboxMode(str, Enum):
3636
DANGER_FULL_ACCESS = "danger-full-access"
3737

3838

39+
class HistoryPersistence(str, Enum):
40+
SAVE_ALL = "save-all"
41+
NONE = "none"
42+
43+
44+
class HistoryConfig(BaseModel):
45+
persistence: HistoryPersistence | None = None
46+
max_bytes: int | None = None
47+
48+
model_config = ConfigDict(extra="allow")
49+
50+
51+
class SandboxWorkspaceWrite(BaseModel):
52+
writable_roots: list[str] | None = None
53+
network_access: bool | None = None
54+
exclude_tmpdir_env_var: bool | None = None
55+
exclude_slash_tmp: bool | None = None
56+
57+
model_config = ConfigDict(extra="allow")
58+
59+
60+
class McpServerConfig(BaseModel):
61+
command: str
62+
args: list[str] | None = None
63+
env: dict[str, str] | None = None
64+
startup_timeout_ms: int | None = None
65+
66+
model_config = ConfigDict(extra="allow")
67+
68+
69+
class WireApi(str, Enum):
70+
CHAT = "chat"
71+
RESPONSES = "responses"
72+
73+
74+
class ModelProviderConfig(BaseModel):
75+
name: str | None = None
76+
base_url: str | None = None
77+
env_key: str | None = None
78+
wire_api: WireApi | None = None
79+
query_params: dict[str, str] | None = None
80+
http_headers: dict[str, str] | None = None
81+
env_http_headers: dict[str, str] | None = None
82+
request_max_retries: int | None = None
83+
stream_max_retries: int | None = None
84+
stream_idle_timeout_ms: int | None = None
85+
86+
model_config = ConfigDict(extra="allow")
87+
88+
89+
class FileOpener(str, Enum):
90+
VSCODE = "vscode"
91+
VSCODE_INSIDERS = "vscode-insiders"
92+
WINDSURF = "windsurf"
93+
CURSOR = "cursor"
94+
NONE = "none"
95+
96+
97+
class ReasoningEffort(str, Enum):
98+
MINIMAL = "minimal"
99+
LOW = "low"
100+
MEDIUM = "medium"
101+
HIGH = "high"
102+
103+
104+
class ReasoningSummary(str, Enum):
105+
AUTO = "auto"
106+
CONCISE = "concise"
107+
DETAILED = "detailed"
108+
NONE = "none"
109+
110+
111+
class ReasoningSummaryFormat(str, Enum):
112+
NONE = "none"
113+
EXPERIMENTAL = "experimental"
114+
115+
116+
class Verbosity(str, Enum):
117+
LOW = "low"
118+
MEDIUM = "medium"
119+
HIGH = "high"
120+
121+
122+
class ToolsConfig(BaseModel):
123+
# Accept either "web_search" or legacy alias "web_search_request" on input
124+
web_search: bool | None = Field(
125+
default=None, validation_alias=AliasChoices("web_search", "web_search_request")
126+
)
127+
# Also expose view_image knob (defaults handled in Rust)
128+
view_image: bool | None = None
129+
130+
model_config = ConfigDict(extra="allow")
131+
132+
133+
class ProfileConfig(BaseModel):
134+
model: str | None = None
135+
model_provider: str | None = None
136+
approval_policy: ApprovalPolicy | None = None
137+
model_reasoning_effort: ReasoningEffort | None = None
138+
model_reasoning_summary: ReasoningSummary | None = None
139+
model_verbosity: Verbosity | None = None
140+
chatgpt_base_url: str | None = None
141+
experimental_instructions_file: str | None = None
142+
143+
model_config = ConfigDict(extra="allow")
144+
145+
146+
class ProjectConfig(BaseModel):
147+
trust_level: str | None = Field(
148+
default=None, description='Only "trusted" is recognized by the core.'
149+
)
150+
151+
model_config = ConfigDict(extra="allow")
152+
153+
154+
class PreferredAuthMethod(str, Enum):
155+
CHATGPT = "chatgpt"
156+
APIKEY = "apikey"
157+
158+
39159
class CodexConfig(BaseModel):
40160
"""Configuration overrides for Codex.
41161
@@ -52,6 +172,7 @@ class CodexConfig(BaseModel):
52172
# Safety/Execution
53173
approval_policy: ApprovalPolicy | None = Field(default=None)
54174
sandbox_mode: SandboxMode | None = Field(default=None)
175+
sandbox_workspace_write: SandboxWorkspaceWrite | None = None
55176

56177
# Environment
57178
cwd: str | None = Field(default=None, description="Working directory for the session.")
@@ -68,7 +189,46 @@ class CodexConfig(BaseModel):
68189
include_apply_patch_tool: bool | None = Field(default=None)
69190
include_view_image_tool: bool | None = Field(default=None)
70191
show_raw_agent_reasoning: bool | None = Field(default=None)
71-
tools_web_search_request: bool | None = Field(default=None)
192+
193+
# Model/runtime tuning
194+
model_context_window: int | None = None
195+
model_max_output_tokens: int | None = None
196+
model_reasoning_effort: ReasoningEffort | None = None
197+
model_reasoning_summary: ReasoningSummary | None = None
198+
model_verbosity: Verbosity | None = None
199+
model_supports_reasoning_summaries: bool | None = None
200+
model_reasoning_summary_format: ReasoningSummaryFormat | None = None
201+
202+
# Auth/UI options
203+
hide_agent_reasoning: bool | None = None
204+
chatgpt_base_url: str | None = None
205+
preferred_auth_method: PreferredAuthMethod | None = None
206+
file_opener: FileOpener | None = None
207+
208+
# Config file composed sections
209+
history: HistoryConfig | None = None
210+
tui: dict[str, Any] | None = None
211+
notify: list[str] | None = None
212+
instructions: str | None = Field(
213+
default=None,
214+
description="Ignored by core; prefer AGENTS.md or experimental_instructions_file.",
215+
)
216+
mcp_servers: dict[str, McpServerConfig] | None = None
217+
model_providers: dict[str, ModelProviderConfig] | None = None
218+
project_doc_max_bytes: int | None = None
219+
profile: str | None = None
220+
profiles: dict[str, ProfileConfig] | None = None
221+
tools: ToolsConfig | None = None
222+
projects: dict[str, ProjectConfig] | None = None
223+
224+
# Experimental / internal
225+
experimental_resume: str | None = None
226+
experimental_instructions_file: str | None = None
227+
experimental_use_exec_command_tool: bool | None = None
228+
responses_originator_header_internal_override: str | None = None
229+
disable_response_storage: bool | None = Field(
230+
default=None, description="Accepted in some clients; ignored by core."
231+
)
72232

73233
def to_dict(self) -> dict[str, Any]:
74234
"""Return overrides as a plain dict with None values removed.

crates/codex_native/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "codex_native"
3-
version = "0.2.9"
3+
version = "0.2.10"
44
edition = "2021"
55

66
[lib]

0 commit comments

Comments
 (0)