[codex] Preserve legacy string-node search during Text rename#13348
Draft
taiyangtandian-star wants to merge 1 commit intoComfy-Org:masterfrom
Draft
[codex] Preserve legacy string-node search during Text rename#13348taiyangtandian-star wants to merge 1 commit intoComfy-Org:masterfrom
taiyangtandian-star wants to merge 1 commit intoComfy-Org:masterfrom
Conversation
The string-node rename updated display names for discoverability, but `StringLength` lost the exact legacy `Length` alias. This restores that alias and adds focused tests for the renamed schema metadata so future renames keep old search paths intact. Constraint: Keep scope limited to the recent string-node rename surface Rejected: Broad schema metadata audit across unrelated nodes | exceeds the changed-area scope for this automation Confidence: high Scope-risk: narrow Reversibility: clean Directive: When renaming nodes for search/discoverability, preserve the previous display name as an alias and lock it with a schema test Tested: uvx pytest tests-unit/comfy_extras_test/nodes_string_test.py Not-tested: Ruff lint, because uvx temporary download stalled in this environment
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.
Issue
The recent string-node rename pass changed display names to the new
Text ...variants, butStringLengthno longer kept its oldLengthdisplay name as a search alias. Users searching for the legacy name would stop finding the node even though the intent of the rename was to preserve discoverability through aliases.Root cause
The rename commit updated aliases for the other renamed string nodes, but
StringLengthonly kept descriptive aliases likecharacter countandstring length. The exact legacy display name was omitted, so this path was left untested and regressed silently.Fix
Add the missing
Lengthsearch alias back toStringLengthand introduce a focused unit test module that verifies:Text ...display names;regexkeyword for search.The new test uses lightweight stubs for the Comfy API import surface so it stays fast and independent from the full runtime dependency graph.
Validation
Validated with:
uvx pytest tests-unit/comfy_extras_test/nodes_string_test.pyI also attempted
uvx --from ruff ruff check comfy_extras/nodes_string.py tests-unit/comfy_extras_test/nodes_string_test.py, but the temporary tool download stalled in this environment, so lint evidence is limited to the targeted test pass.