Repository navigation
Handle unnamed enum.Flag values in the renderer - #83
Closed
Linxiushen wants to merge 1 commit into
Closed
Linxiushen wants to merge 1 commit into
Linxiushen wants to merge 1 commit into
Conversation
Collaborator
|
Closing this PR since the contributions appear to be automated and unrelated to real-world use of this library. |
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.
Rendering a valid
enum.Flagvalue such asPermissions(0)or an unnamedPermissions.READ | Permissions.WRITEcurrently raisesTypeErrororAttributeError: its name is eitherNoneor a composite name that is not a class attribute. The failure occurs through the normal text and HTML rendering APIs with strict error handling.Preserve the existing qualified member form for named members and aliases, and render unnamed flag values as
Permissions(value). Add regression coverage for zero values, combinations, complements, named zero/composite members, aliases, ordinary enums, strict HTML rendering, copy keypaths, and reconstruction from roundtrip text.Validation on Windows with Python 3.12.14:
test_closure_renderingpath assertion is deselected.tests/renderer_test.pyinside a Windows backslash path.pyink treescope tests --check: 64 files unchanged.pylint treescope: 10.00/10.The project's Ubuntu/Python 3.10.14 CI has not been run locally. Both changed files parse with Python 3.10 syntax; that is not runtime or type-checking evidence.
pytypehas not been run on Windows (the locked release has no Windows wheel), so its Linux CI result remains pending.AI assistance: implementation, regression tests and diff review were prepared with Codex.