fix(commands): accept hexadecimal light colors - #73
Merged
Conversation
zoeyrose
marked this pull request as ready for review
August 10, 2026 17:46
zoeyrose
force-pushed
the
fix/69-command-color-parsing
branch
from
August 10, 2026 17:59
e87fd19 to
9bd9590
Compare
zoeyrose
force-pushed
the
fix/69-command-color-parsing
branch
from
August 10, 2026 18:01
9bd9590 to
761a9b7
Compare
zoeyrose
added a commit
that referenced
this pull request
Aug 10, 2026
## Summary - parse `light_color` command values as exactly six unprefixed hexadecimal digits, case-insensitively - validate all light-color input before mutating object attributes - make `/create` destroy an uninserted object and report malformed input cleanly, while `/patch` reports it without mutation - preserve generic decimal, float, quoted-string, flag, and fallback `Load()` coercion - add focused helper and command-adapter regressions to aggregate validation ## Release line This is the separately maintained Classic `1.x` companion for issue #69. PR #73 on `main` is the only canonical closing change. ## Validation - `python3 -m unittest -v tools.tests.test_python_commands`: 9/9 passed - `python3 tools/validate.py`: 99/99 tests passed, including catalog, schema, contracts, release guidance, release-line, clean runtime collection/package, and license gates - `git diff --check`: passed - `./atrinik build server --profile issue-69-classic --test`: 36/36 server tests passed, including lighting, Python plugin, runtime, and protocol coverage - isolated topology `issue-69-command-color` with state `scenario-issue-69-command-color`: server and client reached ready state, completed the QUIC handshake and asset transfer, then shut down cleanly - GitHub Content validation, Linux/Windows syntax prototypes, and PR-title policy: passed on rebased head `7b246116e` - definitive independent whole-diff exit review: zero actionable findings The focused command tests prove `/create` and `/patch` convert `ff0000`/mixed-case `RRGGBB` to the expected integer, reject malformed input without mutation, and destroy an invalid uninserted `/create` object. The isolated server lighting suite verifies the corresponding Classic integer light-color runtime contract. ## Reproduction The preserved credentials-local scenario can be inspected with: ```sh ./atrinik scenario show issue-69-command-color --json ./atrinik scenario credentials issue-69-command-color ./atrinik topology show issue-69-classic --state scenario-issue-69-command-color --json ./atrinik up --name issue-69-command-color --profile issue-69-classic --state scenario-issue-69-command-color ./atrinik ps issue-69-command-color --json ``` Log in with the locally retrieved credentials, run `/create torch light_color ff0000`, apply the torch and observe red light; use `/patch torch light_color 00FF00` for the same parser path; then confirm `/create torch light_color gg0000` reports the validation error without adding an object. Finish with: ```sh ./atrinik logs issue-69-command-color server --tail 100 ./atrinik down issue-69-command-color ``` ## Coordinates - base: `1.x` at `8576f6dcf1d03ecbcbfa55c80b275568b519491b` - head: `fix/69-command-color-parsing-1x` at `7b246116e` - worktree: `/workspaces/atrinik/workspace/worktrees/content-1x/issue-69-1x` - commits: `1e224a91 fix(commands): accept hexadecimal light colors`; `178cd603 fix(commands): preserve unrelated light color text`; `79717621 fix(commands): align attribute whitespace parsing`; `3dc148f3 fix(commands): validate complete color input`; `ea2ab4b0 fix(commands): reject malformed color quoting`; `7b246116 fix(commands): reject quoted color attributes` Companion to #69 and #73.
|
🎉 This PR is included in version 2.1.1 🎉 The release is available on:
Your semantic-release bot 📦🚀 |
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.
Summary
light_colorcommand values as exactly six unprefixed hexadecimal digits, case-insensitively/createdestroy an uninserted object and report malformed input cleanly, while/patchreports it without mutationLoad()coercionRelease line
This is the canonical forward-line change for
main. PR #74 is the separately maintained1.xcompanion with its own base, worktree, commit, validation, and PR.Validation
python3 -m unittest -v tools.tests.test_python_commands: 9/9 passedpython3 tools/validate.py: 100/100 tests passed, including catalog, schema, contracts, syntax, release guidance, clean runtime collection, license, and provenance gatesgit diff --check: passed761a9b764The replacement stack does not yet expose wrapper build, runtime, or scenario adapters for authored content; that existing boundary is tracked in
atrinik/atrinik#266,#269, and#270. This branch therefore uses its repository-owned validation and focused command-adapter coverage rather than importing Classic runtime code.Coordinates
mainat040e63d96cb50eb1afc8e819297ee3859ad34620fix/69-command-color-parsingat761a9b764/workspaces/atrinik/workspace/worktrees/content/issue-69-mainea5370c50 fix(commands): accept hexadecimal light colors;e0d5c89f0 fix(commands): preserve unrelated light color text;eb2025ca0 fix(commands): align attribute whitespace parsing;b2f93d0fb fix(commands): validate complete color input;41901080c fix(commands): reject malformed color quoting;761a9b764 fix(commands): reject quoted color attributesCloses #69
Companion: #74