fix(tirith): cache OSError spawn failure to suppress repeated WARNING spam#23880
Closed
ms-alan wants to merge 1 commit into
Closed
fix(tirith): cache OSError spawn failure to suppress repeated WARNING spam#23880ms-alan wants to merge 1 commit into
ms-alan wants to merge 1 commit into
Conversation
… spam When tirith is not installed on Windows but 'tirith' appears in PATH (e.g. from MSYS/Git Bash), shutil.which() returns a MSYS-style path (/mingw64/bin/tirith) that exists on disk but cannot be executed by Windows subprocess. The OSError was raised on every command without caching the failure, causing the same WARNING to fire 20+ times per session. Fix: mark _resolved_path = _INSTALL_FAILED in the OSError handler so subsequent check_command_security() calls short-circuit to 'path unavailable' (one WARNING) instead of retrying the same broken path. Closes NousResearch#23845
Collaborator
This was referenced May 15, 2026
Merged
Contributor
|
This looks resolved on current main by the merged tirith warning-spam fixes. This is an automated hermes-sweeper review. Evidence:
Thanks for the focused fix. The exact internal mechanism on main differs slightly from this PR, but the reported repeated WARNING spam is covered now. |
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.
Closes #23845
Summary
When tirith is not installed on Windows but 'tirith' appears in PATH (e.g. from MSYS/Git Bash), returns a MSYS-style path () that exists on disk but cannot be executed by Windows subprocess. The was raised on every command without caching the failure, causing the same to fire 20+ times per session.
Fix
In OSError handler, set so subsequent calls short-circuit to 'path unavailable' (fires once) instead of retrying the same broken path and re-logging the same WARNING.
Testing