Skip to content

fix(env)!: route release_env through IEx chat and resume - #174

Merged
joshrotenberg merged 2 commits into
mainfrom
fix/156-iex-release-env
Nov 2, 2026
Merged

joshrotenberg merged 2 commits into
mainfrom
fix/156-iex-release-env

Conversation

@joshrotenberg

@joshrotenberg joshrotenberg commented Nov 1, 2026 •

Copy link
Copy Markdown
Collaborator

Follow-up to #170 for #156.

Passing release_env to CodexWrapper.IEx.chat/2 or resume/2 routed it as an exec option and raised an unknown-option error. Both entry points now store it in config, and later say/2 calls retain the selected policy.

  • Add four fake-CLI regression tests covering :inherit and :scrub through both entry points and later turns. The tests inspect actual child variables and PATH.
  • Document {String.t(), String.t() | false} environment entries in the runner typedoc, with false removing an inherited variable on every implemented callback.
  • Clarify the custom-runner requirement in the existing breaking CHANGELOG entry.

Validation completed before pushing commit a87d02da6b4e1262c81e50a9223c185a1f979392:

Environment Result
Elixir 1.19.7 / OTP 27.3.4.19, Linux arm64 Full CI check set passed; 765 tests, 0 failures, 4 integration exclusions
Elixir 1.20.5 / OTP 29.1.2, Linux arm64 Full CI check set passed; 765 tests, 0 failures, 4 integration exclusions
Elixir 1.19.7 / OTP 27.3.4.19 docs mix docs --warnings-as-errors passed
Node 22.23.4 CLI contracts mix codex.contract passed for 0.149.0, 0.164.0, and latest 0.166.0

The full CI check set includes mix deps.get, mix deps.unlock --check-unused, mix hex.audit, mix compile --warnings-as-errors, mix format --check-formatted, mix credo --strict, mix dialyzer, and mix test. The real Forcola shim ran in both runtime suites. Only the four opt-in authenticated integration tests were excluded. git diff --check also passed.

GitHub CI passed all five PR jobs on the same commit: both runtime jobs, docs, and both pinned CLI contracts.

The squash commit must keep the ! title and the BREAKING CHANGE: footer so the release environment scrub introduced in #170 is declared as breaking on main.

Route release_env through config for chat and resume so later say calls
retain the policy. Test inherited and scrubbed child variables and PATH.
Document false environment values in the runner typedoc and the
CHANGELOG sentence for the release environment scrub.
@joshrotenberg
joshrotenberg marked this pull request as ready for review November 1, 2026 14:28
@joshrotenberg joshrotenberg changed the title fix(env): route release_env through IEx chat and resume fix(env)!: route release_env through IEx chat and resume Nov 1, 2026
BREAKING CHANGE: Child processes launched inside an Elixir release, when RELEASE_ROOT is set, now scrub RELEASE_*, BINDIR, ROOTDIR, and release PATH entries by default, as introduced in #170. Set release_env: :inherit to opt out. Custom runners must honour {name, false} entries in opts[:env] by removing those variables from the inherited environment on every implemented execution callback.
@joshrotenberg
joshrotenberg merged commit e40ebed into main Nov 2, 2026
5 checks passed
@joshrotenberg
joshrotenberg deleted the fix/156-iex-release-env branch November 2, 2026 23:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant