fix(shared): preserve empty legacy image payloads - #426
Merged
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughLegacy image decoding now normalizes empty and whitespace-only payloads, including exact empty Base64 data URLs, to empty byte arrays. Tests cover normalization and decoding of empty layer and cel image data. ChangesLegacy image compatibility
Estimated code review effort: 2 (Simple) | ~10 minutes 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
Flow-Fly
marked this pull request as ready for review
July 28, 2026 12:56
Owner
Author
|
Hotfix ready for owner merge at exact head
After merge, draft reconciliation PR #424 will be regenerated from corrected |
This was referenced Jul 28, 2026
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
base64data URLsdecodeProjectFilecoverage for representative legacy layer and cel payloadsLinked task issues
Closes #425
Regression evidence
Before the production change,
npx vitest run tests/shared/project-contract.test.tsfailed both new cases withTypeError: Legacy project image data is emptyatshared/src/project-data.ts:71; the other 11 contract tests passed.After the fix,
npm run shared:build && npx vitest run tests/shared/project-contract.test.ts tests/serialization/project-data.test.tspasses all 30 tests.Verification
npm run shared:check(21 tests, including Node ESM import)npx tsc --noEmitnpm run lint(passes with 5 pre-existing warnings, 0 errors)npm run test:run(112 files, 707 tests, plus Node ESM import)npm run buildnpm run fallow:auditgit diff --checkNo project format version, migration, or persisted schema changes.
Summary by CodeRabbit