Skip to content

feat(metadata): Warn on unknown previews; clear old previews#3603

Draft
EvanBacon wants to merge 1 commit intomainfrom
@evanbacon/metadata/preview-warnings
Draft

feat(metadata): Warn on unknown previews; clear old previews#3603
EvanBacon wants to merge 1 commit intomainfrom
@evanbacon/metadata/preview-warnings

Conversation

@EvanBacon
Copy link
Copy Markdown
Contributor

Validate preview types and improve cleanup to avoid Apple limits.

  • In PreviewsTask.uploadAsync, skip unknown preview types and emit warnings. If the type uses an APP_ prefix and the stripped type is valid, suggest the corrected type. Also log the list of valid preview types.
  • In syncPreviewSetAsync, delete all existing previews before uploading the new one to avoid "Too many app previews" errors (Apple limits each set to 3 previews).
  • Add tests covering APP_ prefix suggestion and fully unknown preview types, and mock the Log module in tests.

Validate preview types and improve cleanup to avoid Apple limits.

- In PreviewsTask.uploadAsync, skip unknown preview types and emit warnings. If the type uses an APP_ prefix and the stripped type is valid, suggest the corrected type. Also log the list of valid preview types.
- In syncPreviewSetAsync, delete all existing previews before uploading the new one to avoid "Too many app previews" errors (Apple limits each set to 3 previews).
- Add tests covering APP_ prefix suggestion and fully unknown preview types, and mock the Log module in tests.
@github-actions
Copy link
Copy Markdown

❌ It looks like a changelog entry is missing for this PR. Add it manually to CHANGELOG.md.
⏩ If this PR doesn't require a changelog entry, such as if it's an internal change that doesn't affect the user experience, you can add the "no changelog" label to the PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant