Repository navigation
chore(server): drop redundant ray_enabled = False declarations - #4470
Merged
Merged
Conversation
ray_enabled now defaults to False, so only servers that use Ray need to declare it. Remove the explicit `ray_enabled = False` from the 212 server classes that set it, and from the scaffold templates for new resources and agent servers. Before removing each line, I checked that no class declared False to override a parent that declares True: every one inherits False from its parents, so behavior is unchanged. The source audit now checks that servers declare ray_enabled = True exactly when they use Ray. It accepts an explicit False on other servers, so syncing this into a branch that still has them doesn't fail. Signed-off-by: Ananth Subramaniam <[email protected]>
Contributor
marta-sd
approved these changes
Oct 13, 2026
Contributor
|
🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA-NeMo/Gym/actions/runs/38381015082 |
tanishku
added a commit
to tanishku/Gym
that referenced
this pull request
Oct 14, 2026
Complying with NVIDIA-NeMo#4470, we have removed the line. Signed-off-by: Tanish Kushalkar <[email protected]>
5 tasks done
7 tasks done
yaoyu-33
added a commit
to yaoyu-33/Gym
that referenced
this pull request
Oct 19, 2026
Resolves three modify/delete conflicts in `responses_api_agents/hermes_sandboxed_agent/` by keeping this branch's deletion. Since the merge base, main changed that directory in four commits: - NVIDIA-NeMo#3886 made the adapter a checkpoint participant, sending `CHECKPOINT_CLOSE_FOLLOWS_HEADER` on close. - A hardening change added `MAX_OUTPUT_BYTES` and `_download_output_tail`, bounding harness output inside the sandbox before transfer. - NVIDIA-NeMo#3902 and NVIDIA-NeMo#4470 made incidental edits. Discarding that work is deliberate. The checkpoint participation it added is not lost: NVIDIA-NeMo#3886 gave the same header to the environment servers, so `environment_servers/single_agent_turn/app.py` already sends it on the session path this branch migrates to. The output-bounding change applied only to the removed runner; the retained agent reads its harness log through `SandboxSession.read_output_log`, which is unbounded, so that gap is tracked separately against the retained path rather than carried here. No reference to the removed component survives outside the migration note in `responses_api_agents/hermes_agent/README.md`, and nothing main added since the merge base refers to it. Co-Authored-By: Claude Opus 5 <[email protected]> Signed-off-by: yaoyu-33 <[email protected]>
8 of 26 tasks
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changed
ray_enableddefaults toFalsesince #4307, so only servers that use Ray need to declare it.ray_enabled = Falsefrom the 212 classes that set it, across resources, agent, model and environment servers. The 18 servers that use Ray keepray_enabled = True.ray_enabled = False.tests/unit_tests/test_ray_opt_out.py): checks that a server class declaresray_enabled = Trueexactly when it uses Ray. It still accepts an explicitFalse, so syncing this change into a branch that still has those lines doesn't fail.ray_enabled = True" instead of "servers declaringray_enabled = False".Why
The explicit declarations were needed while an undeclared server still defaulted to using Ray. Now they're noise, and the scaffold kept copying them into new servers. The only declaration that carries information is
ray_enabled = True.Part of #3669.
Validation
Falseto override a parent that declaresTrue. All 212 inheritFalse. Seventeen of them inherit through theGymnasiumServer,AviaryResourcesServerandLangGraphAgentAdapterbase classes, which I checked directly.Truefromcode_genfails it with "uses Ray but doesn't declareray_enabled = True";Truetomcqafails it with "declaresray_enabled = Truebut doesn't use Ray".tests/unit_tests/run with-m "not sandbox"in the core CI job's environment (with--extra ray) passes.fern checkpasses.pre-commit runon the changed files.Rollout evidence
Smoke run:
gym env startwithexample_single_tool_callandopenai_model. All four servers (resources, simple agent, legacy agent environment server and OpenAI model) no longer mentionray_enabled. All four reached ready without starting Ray and without warnings. No model requests were sent. Declarations only; this doesn't change prompts, trajectories, verification or rewards.Compatibility
None. Servers that don't declare
ray_enabledalready getFalse. External servers that still declareray_enabled = Falsekeep working.