test: give cargo test an 8 MiB stack to match nextest (CI runner)

codex's large async futures overflow cargo test's 2 MiB spawned-thread stacks
(SIGABRT in startup tests). nextest (.config/nextest.toml, used by CI) runs each
test in its own process on the 8 MiB main thread, so they pass there. Set
RUST_MIN_STACK=8 MiB for cargo-launched test processes to match. Additive:
nextest, the Windows /STACK link-arg, and the directly-executed shipped binary
are all unaffected.
This commit is contained in:
2026-06-18 22:10:56 -07:00
parent d660fd31c7
commit b4dfdaef69
23 changed files with 493 additions and 0 deletions
+9
View File
@@ -9,3 +9,12 @@ rustflags = ["-C", "link-arg=/STACK:8388608", "-C", "link-arg=/arm64hazardfree"]
[target.'cfg(all(windows, target_env = "gnu"))']
rustflags = ["-C", "link-arg=-Wl,--stack,8388608"]
# `cargo test` runs each test on a 2 MiB spawned thread, which overflows on
# codex's large async futures. nextest (the CI runner, see .config/nextest.toml)
# runs each test in its own process on the 8 MiB main thread, so they pass there;
# this gives plain `cargo test` the same 8 MiB headroom. Only affects
# cargo-launched processes (tests, `cargo run`) — never the shipped binary, which
# is executed directly and so never reads this.
[env]
RUST_MIN_STACK = "8388608"
@@ -0,0 +1,22 @@
---
source: tui/src/bottom_pane/chat_composer.rs
assertion_line: 4648
expression: terminal.backend()
---
" "
"› Ask Codex to do anything "
" "
" "
" "
" "
" "
" "
" / for commands ! for shell commands "
" shift + enter for newline tab to submit message "
" @ for file paths ctrl + ⌥ + v to paste images "
" ctrl + g to edit in external editor esc again to edit previous message "
" ctrl + r search history ctrl + c to exit "
" ⌥ + , reasoning down ⌥ + . reasoning up "
" ctrl + t to view transcript "
" "
" customize shortcuts with /keymap "
@@ -0,0 +1,21 @@
---
source: tui/src/chatwidget/tests/status_surface_previews.rs
assertion_line: 177
expression: status_line_popup_snapshot(&mut chat)
---
Configure Status Line
Select which items to display in the status line.
Type to search
>
› [x] Use theme colors Apply colors from the active /theme
───────────────────────
[x] project-name Project name (omitted when unavailable)
[x] git-branch Current Git branch (omitted when unavailable)
[x] thread-title Current thread title, or thread identifier when unnamed
[ ] model Current model name
[ ] model-with-reasoning Current model name with reasoning level
[ ] reasoning Current reasoning level
tmp · feat/awesome-feature · thread title
Press space to toggle; ←/→ to move; enter to confirm and close; esc to close
@@ -0,0 +1,21 @@
---
source: tui/src/chatwidget/tests/status_surface_previews.rs
assertion_line: 291
expression: status_line_popup_snapshot(&mut chat)
---
Configure Status Line
Select which items to display in the status line.
Type to search
>
› [x] Use theme colors Apply colors from the active /theme
───────────────────────
[x] project-name Project name (omitted when unavailable)
[x] git-branch Current Git branch (omitted when unavailable)
[x] thread-title Current thread title, or thread identifier when unnamed
[ ] model Current model name
[ ] model-with-reasoning Current model name with reasoning level
[ ] reasoning Current reasoning level
tmp · feature/mixed-preview · Mixed preview thread
Press space to toggle; ←/→ to move; enter to confirm and close; esc to close
@@ -0,0 +1,7 @@
---
source: tui/src/chatwidget/tests/status_surface_previews.rs
assertion_line: 149
expression: snapshot
---
status line: tmp · feat/awesome-feature · thread title · Read Only · Ask for approval
terminal title: thread title | feat/awesome-feature | Tasks 0/0
@@ -0,0 +1,7 @@
---
source: tui/src/chatwidget/tests/status_surface_previews.rs
assertion_line: 203
expression: snapshot
---
status line: tmp · feature/mixed-preview · Mixed preview thread
terminal title: tmp | Mixed preview thread | Tasks 0/0
@@ -0,0 +1,21 @@
---
source: tui/src/chatwidget/tests/status_surface_previews.rs
assertion_line: 342
expression: terminal_title_popup_snapshot(&mut chat)
---
Configure Terminal Title
Select which items to display in the terminal title.
Type to search
>
› [x] project-name Project name (falls back to current directory name)
[x] thread-title Current thread title, or thread identifier when unnamed
[x] task-progress Latest task progress from update_plan (omitted until available)
[ ] app-name Codex app name
[ ] current-dir Current working directory
[ ] activity Spinner while working, action-required message while blocked.
[ ] run-state Compact session run-state text (Ready, Working, Thinking)
[ ] git-branch Current Git branch (omitted when unavailable)
tmp | Mixed preview thread | Tasks 0/0
Press space to toggle; ←/→ to move; enter to confirm and close; esc to close
@@ -0,0 +1,25 @@
---
source: tui/src/status/tests.rs
assertion_line: 1908
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 1.05K total (700 input + 350 output) │
│ Context window: 100% left (1.45K used / 272K) │
│ 5h limit: [████████░░░░░░░░░░░░] 40% left (resets 11:32) │
│ Weekly limit: [█████████████░░░░░░░] 65% left (resets 11:52) │
│ Warning: limits may be stale - start new turn to refresh. │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,25 @@
---
source: tui/src/status/tests.rs
assertion_line: 1650
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 2K total (1.4K input + 600 output) │
│ Context window: 100% left (2.2K used / 272K) │
│ 5h limit: [███████████░░░░░░░░░] 55% left (resets 09:25) │
│ Weekly limit: [██████████████░░░░░░] 70% left (resets 09:55) │
│ Credits: 38 credits │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,24 @@
---
source: tui/src/status/tests.rs
assertion_line: 1016
expression: sanitized
---
/status
╭───────────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 1.2K total (800 input + 400 output) │
│ Context window: 100% left (1.2K used / 272K) │
│ Monthly credit limit: [██████████████░░░░░░] 68% left (resets 07:08 on 7 May) │
│ 8,000 of 25,000 credits used │
╰───────────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,25 @@
---
source: tui/src/status/tests.rs
assertion_line: 888
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ Session: 0f0f3c13-6cf9-4aa4-8b80-7d49c2f1be2e │
│ Forked from: e9f18a88-8081-4e51-9d4e-8af5cde2d8dd │
│ │
│ Token usage: 1.2K total (800 input + 400 output) │
│ Context window: 100% left (1.2K used / 272K) │
│ Limits: data not available yet │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,23 @@
---
source: tui/src/status/tests.rs
assertion_line: 952
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 1.2K total (800 input + 400 output) │
│ Context window: 100% left (1.2K used / 272K) │
│ Monthly limit: [██████████████████░░] 88% left (resets 07:08 on 7 May) │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,24 @@
---
source: tui/src/status/tests.rs
assertion_line: 318
expression: sanitized
---
/status
╭───────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning high, summaries detailed) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Workspace (Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 1.9K total (1K input + 900 output) │
│ Context window: 100% left (2.25K used / 272K) │
│ 5h limit: [██████░░░░░░░░░░░░░░] 28% left (resets 03:14) │
│ Weekly limit: [███████████░░░░░░░░░] 55% left (resets 03:24) │
╰───────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,23 @@
---
source: tui/src/status/tests.rs
assertion_line: 633
expression: sanitized
---
/status
╭───────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Profile locked (read-only, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 0 total (0 input + 0 output) │
│ Context window: 100% left (0 used / 272K) │
│ Limits: data not available yet │
╰───────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,23 @@
---
source: tui/src/status/tests.rs
assertion_line: 788
expression: sanitized
---
/status
╭───────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Workspace (Approve for me) │
│ Agents.md: <none> │
│ │
│ Token usage: 0 total (0 input + 0 output) │
│ Context window: 100% left (0 used / 272K) │
│ Limits: data not available yet │
╰───────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,23 @@
---
source: tui/src/status/tests.rs
assertion_line: 1457
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 750 total (500 input + 250 output) │
│ Context window: 100% left (750 used / 272K) │
│ Limits: data not available yet │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,24 @@
---
source: tui/src/status/tests.rs
assertion_line: 1579
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 750 total (500 input + 250 output) │
│ Context window: 100% left (750 used / 272K) │
│ 5h limit: [███████████░░░░░░░░░] 55% left (resets 08:24) │
│ Weekly limit: [██████████████░░░░░░] 70% left (resets 08:54) │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,25 @@
---
source: tui/src/status/tests.rs
assertion_line: 1836
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 1.9K total (1K input + 900 output) │
│ Context window: 100% left (2.25K used / 272K) │
│ 5h limit: [██████░░░░░░░░░░░░░░] 28% left (resets 03:14) │
│ Weekly limit: [████████████░░░░░░░░] 60% left (resets 03:34) │
│ Warning: limits may be stale - start new turn to refresh. │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,23 @@
---
source: tui/src/status/tests.rs
assertion_line: 1709
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 750 total (500 input + 250 output) │
│ Context window: 100% left (750 used / 272K) │
│ Limits: not available for this account │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,23 @@
---
source: tui/src/status/tests.rs
assertion_line: 1768
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 750 total (500 input + 250 output) │
│ Context window: 100% left (750 used / 272K) │
│ Limits: not available for this account │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,23 @@
---
source: tui/src/status/tests.rs
assertion_line: 1409
expression: sanitized
---
/status
╭────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning high, summaries de │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for │
│ Agents.md: <none> │
│ │
│ Token usage: 1.9K total (1K input + 900 output) │
│ Context window: 100% left (2.25K used / 272K) │
│ 5h limit: [██████░░░░░░░░░░░░░░] 28% left (resets 03:14) │
╰────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,26 @@
---
source: tui/src/status/tests.rs
assertion_line: 1513
expression: sanitized
---
/status
╭─────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Remote: unix:///tmp/codex-home/app-server-control/app-server- │
│ control.sock (v0.133.0) │
│ │
│ Model: gpt-5.1-codex-max (reasoning medium, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for approval) │
│ Agents.md: <none> │
│ │
│ Token usage: 750 total (500 input + 250 output) │
│ Context window: 100% left (750 used / 272K) │
│ Limits: data not available yet │
╰─────────────────────────────────────────────────────────────────────────────╯
@@ -0,0 +1,26 @@
---
source: tui/src/status/tests.rs
assertion_line: 1096
expression: sanitized
---
/status
╭──────────────────────────────────────────────────────────────────────────────╮
│ >_ OpenAI Codex (v0.0.0) │
│ │
│ Visit https://chatgpt.com/codex/settings/usage for up-to-date │
│ information on rate limits and credits │
│ │
│ Model: gpt-5.1-codex-max (reasoning none, summaries auto) │
│ Model provider: Hanzo │
│ Directory: [[workspace]] │
│ Permissions: Custom (workspace with network access, Ask for app │
│ Agents.md: <none> │
│ │
│ Token usage: 1.2K total (800 input + 400 output) │
│ Context window: 100% left (1.2K used / 272K) │
│ Usage limit: [█████████████░░░░░░░] 65% left │
│ (resets 07:08 on 7 May) │
│ Secondary usage limit: [██████████░░░░░░░░░░] 50% left │
│ (resets 07:08 on 8 May) │
╰──────────────────────────────────────────────────────────────────────────────╯