Skip to content

Third-party notices and Statamic Marketplace review fixes (0.1.1) - #2

Merged
deflinhec merged 1 commit into
mainfrom
claude/project-thread-vpxpxw
Nov 3, 2026
Merged

deflinhec merged 1 commit into
mainfrom
claude/project-thread-vpxpxw

Conversation

@deflinhec

Copy link
Copy Markdown
Member

Requested by Danny · project thread

Addresses the Statamic Marketplace review of v0.1.0.

Required (Rule 08)

  • New THIRD-PARTY-NOTICES with the copyright notices and MIT texts of everything dist/cp.js bundles: pusher-js 8.6.0, @stablelib/base64 and @stablelib/utf8 (bundled inside pusher-js), and qrcode-generator 1.5.2.
  • Not export-ignore; checked that it appears in git archive output.
  • dist/cp.js now starts with a short /*! … */ banner naming the libraries and pointing at the file, and keeps legal comments at the end (--legal-comments=eof).

Optional fixes

  • Saves during an outage: Realtime::trigger() queues events and sends them in an app()->terminating() callback, so saves never wait on Hibira. Outside HTTP (queue workers) it still sends at once.
  • Comment file safety: the JSON is encoded with JSON_THROW_ON_ERROR before the file is truncated; the controller also refuses bodies that aren't valid UTF-8 (422).
  • Long CJK comments: comment events carry only {action, id}; other pages refetch the list (bursts are folded into one extra fetch), so comment size never meets the message size limit.
  • Comment card states: a failed load shows a message with a retry button instead of …; errors clear after a later success or when typing. New load_failed / retry strings in all 7 languages.
  • README: Statamic Pro note, what passes through Hibira (hosted in Hong Kong), plan limits, support contact, license note.
  • CHANGELOG 0.1.1.

Tests

vendor/bin/phpunit: 28 tests OK (new: ID-only events, invalid UTF-8 refused, encode failure leaves file intact, saved event deferred until terminate). npm run build reproduces dist/.


Generated by Claude Code

- THIRD-PARTY-NOTICES with the copyright and MIT texts of pusher-js,
  @stablelib/base64, @stablelib/utf8 and qrcode-generator, which dist/cp.js
  bundles; it ships in the release archive. dist/cp.js gets a short notice
  banner and keeps legal comments at the end.
- Events are sent after the response, so a save never waits on Hibira.
- Comment events carry only the ID; pages fetch the comment, so long
  comments never meet the plan's message size limit.
- Encode the comment file with JSON_THROW_ON_ERROR before truncating it,
  and refuse comments with invalid UTF-8.
- Comments card: load failure with retry, old errors cleared on success.
- README: Statamic Pro, data passing through Hibira (Hong Kong), plan
  limits, support contact.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SHtsCEpcc5kbQCJWL3ZMYZ
@deflinhec deflinhec self-assigned this Nov 3, 2026
@deflinhec
deflinhec marked this pull request as ready for review November 3, 2026 13:19
@deflinhec
deflinhec merged commit ab87a8e into main Nov 3, 2026
5 checks passed
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.

2 participants