fix(cli): honor an explicit /journey --reveal 0 instead of rendering 100% - #880
Open
hashbender wants to merge 1 commit into
Open
fix(cli): honor an explicit /journey --reveal 0 instead of rendering 100%#880hashbender wants to merge 1 commit into
hashbender wants to merge 1 commit into
Conversation
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 does this PR do?
Makes an explicit
/journey --reveal 0render the oldest (0%) frame instead of the fully-revealed (100%) one._cmd_show(hermes_cli/journey.py) coerces the flag with:--reveal 0parses (argparsetype=float) to0.0, which is falsy, soor 1.0silently replaces it with the default — the exact opposite of what the flag's own help text documents ("0=oldest, 1=now"). Reachable from bothhermes journey --reveal 0and the interactive/journey --reveal 0. Every other value (0.25, 0.5, …) works, which makes the endpoint failure look like a rendering bug rather than an argument-parsing one.The fix treats only a missing value as the fully-revealed default;
0.0clamps through unchanged.Related Issue
None filed; introduced with the /journey feature (NousResearch#55555).
Type of Change
Changes Made
hermes_cli/journey.py— replace the falsy-swallowingor 1.0with an explicit None-check (+ comment).tests/hermes_cli/test_journey_render.py— 3 contract tests running the realargs.funcpath and asserting therevealvalue that reaches the frame renderer:--reveal 0→0.0, no flag →1.0,--reveal 0.25→ passthrough.How to Test
test_reveal_zero_renders_oldest_framefails on current main (renderer receives1.0) and passes with the fix; the other 4 tests (including the two pre-existing ANSI-routing contracts) pass on both. macOS 15.scripts/check-windows-footguns.pyclean.Checklist
Mirror-of: NousResearch#57095
NousResearch#57095