Commit Graph
36 Commits
Author SHA1 Message Date
翅膀 ceb906d479 fix(target): normalize actual destinations
Different target spellings can name the same actual destination.
Normalize channel, thread and topic identities for ownership checks
and per-route duplicate suppression.
2026-10-23 23:23:22 +08:00
翅膀 0978c6c310 fix(feishu): authenticate and dedupe callbacks
Authenticate signed or token-verified callbacks before dispatching
commands. Decode encrypted envelopes and handle card actions using
the correct fields without claiming irrelevant chat events.
2026-10-23 23:23:21 +08:00
翅膀 e850ec3c14 fix(feishu): neutralize untrusted mentions
Forge text is untrusted and can contain at-all tags.
Neutralize mentions in card bodies and footers before rendering.
2026-10-23 23:23:19 +08:00
翅膀 4c1ec472af fix(feishu): use the card update endpoint
Delayed card updates use the card update endpoint; the config
endpoint cannot update an interaction response.
2026-10-23 23:23:18 +08:00
翅膀 832718a238 fix(feishu): refresh and evict tokens safely
Separate app token caches, stop reusing refused tokens and share
refreshes. Cache failures briefly and keep valid tokens in memory
when a best-effort KV cache write fails.
2026-10-23 23:23:17 +08:00
翅膀 1b814b4dfa fix(feishu): retry sends with stable uuids
An unreadable response does not prove a send failed.
Reuse the same uuid for retries so recovering the result cannot
create a second Feishu message.
2026-10-23 23:23:16 +08:00
翅膀 fa3b090dd6 fix(feishu): classify retryable api failures
Business error codes can be transient even in HTTP 200 responses.
Classify token and rate-limit errors for retry and defer long waits.
2026-10-23 23:23:14 +08:00
翅膀 061e045a39 fix(feishu): bound individual api requests
Bound individual platform calls so they cannot outlive the lock
protecting a message update or stall a whole delivery invocation.
2026-10-23 23:23:13 +08:00
翅膀 7882701e1f fix(telegram): keep completed commands claimed
Redelivery after a completed write must never post another comment.
Keep completion claims despite reply failures, scope updates per bot
and only issue account-login links in private chats.
2026-10-23 23:23:11 +08:00
翅膀 8b10b98880 fix(telegram): honor the author emoji toggle
The author marker must obey the group emoji preference just like
formatter-added decoration.
2026-10-23 23:23:10 +08:00
翅膀 7a76cac8a1 fix(telegram): clamp visible html characters
Telegram counts visible characters, not HTML source bytes.
Truncate without splitting tags, entities or surrogate pairs.
2026-10-23 23:23:08 +08:00
翅膀 93650141f7 fix(telegram): render hard breaks as newlines
Telegram HTML does not support br tags. Render Markdown hard breaks
as plain newlines so otherwise valid messages are accepted.
2026-10-23 23:23:06 +08:00
翅膀 dd45e13cb1 fix(telegram): keep editable messages as text
Guessing photo versus text from message content makes later edits
use the wrong API and a smaller caption budget. Always send text
and use the avatar as a link preview.
2026-10-23 23:23:05 +08:00
翅膀 867d2af6ac fix(telegram): report unreadable send results
An unreadable successful response may already have sent the message.
Report an explicit uncertain result instead of retrying a create
without an idempotency key or pretending it succeeded.
2026-10-23 23:23:03 +08:00
翅膀 b212989c05 fix(telegram): honor nested rate-limit delays
Telegram places retry_after inside parameters, not at the top level.
Read that value and defer long waits to the delivery queue.
2026-10-23 23:23:02 +08:00
翅膀 03021f7c2b fix(telegram): bound individual api requests
Bound individual platform calls so they cannot outlive the lock
protecting a message update or stall a whole delivery invocation.
2026-10-23 23:22:58 +08:00
翅膀 0bf18fe2ca fix(telegram): always verify webhook secrets
Webhook verification must not silently disable itself when the
optional secret is absent. Derive a stable secret from the bot
token and reject callbacks when verification is unavailable.
2026-10-23 23:22:57 +08:00
翅膀 706737ca6b fix(discord): defer and deduplicate interactions
Acknowledge slow actions before Discord times out and deduplicate
interaction writes. Preserve comment text and reject edits whose
source changed after the modal opened.
2026-10-23 23:22:53 +08:00
翅膀 f8329035e3 fix(discord): resume bounded command syncs
Application changes, command rollbacks and large guild lists can
leave commands stale indefinitely. Track the current hash per app
and resume bounded paginated work without needless KV writes.
2026-10-23 23:22:35 +08:00
翅膀 bfbdf3b159 fix(discord): constrain embeds and role mentions
Respect combined embed and component limits as well as field caps.
Restrict allowed mentions to validated route roles so payload text
cannot notify everyone.
2026-10-23 23:22:31 +08:00
翅膀 7cf507f654 fix(discord): reuse nonces after lost responses
A successful create may lose its response. Reuse a stable nonce
with enforce_nonce so retries recover that message instead of
posting duplicates or accepting an unreadable success.
2026-10-23 23:22:29 +08:00
翅膀 966403bdc1 fix(discord): encode channel path segments
Stored channel and message ids are path segments, not URL paths.
Encode them so aliases cannot address another Discord resource.
2026-10-23 23:22:25 +08:00
翅膀 0761c4bc5a fix(discord): defer long rate-limit waits
Long rate-limit sleeps block delivery progress inside a worker.
Return a retryable 429 for the queue when the wait exceeds the bound.
2026-10-23 23:22:21 +08:00
翅膀 ffd6cf5a36 fix(discord): bound individual api requests
An unbounded API request can outlive an update-chain lock.
Bound each request so another holder cannot race a late edit.
2026-10-23 23:22:17 +08:00
RhenCloud 2e89c79e9c fix(telegram): render rich header title as plain text 2026-09-13 13:13:09 +08:00
github-actions[bot] 1375db9a20 chore: auto-fix lint & formatting [skip ci] 2026-08-26 16:39:02 +00:00
RhenCloud 4b99f6d33d feat(feishu): add Feishu inbound webhook, /gh commands and card actions
- add feishu_links D1 table and link store helpers
- implement X-Lark-Signature verification, url_verification, /gh login|logout|comment|merge|close and card.action.trigger Merge/Close
- render interactive cards with clickable title link, inline links and callback buttons (no whole-card card_link)
- bind Feishu account in OAuth callback
- document event subscription and required scopes
2026-08-27 00:07:05 +08:00
RhenCloud 9899cd01bf fix(telegram): render HTML with markdown-it and strip HTML from Discord bodies 2026-08-24 22:51:26 +08:00
RhenCloud 7ac7bb7958 fix(render): link title head to the event object URL 2026-08-15 18:25:23 +08:00
github-actions[bot] 92ba2203a5 chore: auto-fix lint & formatting [skip ci] 2026-08-15 04:05:25 +00:00
RhenCloud 7ebd9aa63f fix: prevent race conditions with KV locks in dispatch and group provisioning 2026-08-15 12:04:37 +08:00
github-actions[bot] 17d10db845 chore: auto-fix lint & formatting [skip ci] 2026-08-14 00:10:56 +00:00
RhenCloud 3dce114cec feat(groups): optional forge source label in message footers
- Group.forgeLabel (default off, editable per group in the console) shows the
  source forge on every message the group's routes dispatch
- Discord embed footer: forge name next to the repo + the site's favicon as
  icon_url (Gitea instance's own favicon from its origin)
- Telegram footer: hyperlinked site name (GitHub or Gitea hostname); custom
  webhooks render a plain 'Custom' label
- forgeInfo() derives branding from event.provider + repository.html_url;
  dispatch attaches it to the NeutralMessage like mentionRoleIds
- validateGroups accepts forgeLabel booleans; GroupEditor gains the toggle
- tests: forgeInfo unit, discord/telegram footer render, dispatch on/off
- docs: groups.md + message-format.md (en/zh), config.example.yaml, AGENTS.md
- fix: wrangler.jsonc compatibility_date was an incomplete '2026-'
2026-08-14 08:10:04 +08:00
RhenCloud a5324fb0ea fix(formatters): localize PR buttons, cap oversized content, dedupe status logic
- PR merge/close button labels now follow the group language (actions.merge/close)
  instead of hardcoded Chinese
- clamp content to Discord embed limits (title 256, description 4096, field value
  1024, 25 fields) in formatters plus a render-layer safety net; Telegram gets a
  tag-safe 4096-char cap (capHtml closes dangling tags)
- raise commit subject truncation from 72 to 200 chars (MAX_COMMIT_SUBJECT)
- extract workflowStatus/workflowRunStatus/statusColorKey helpers shared by
  check_run/check_suite/workflow_run/workflow_job
- dedupe deployment ref/sha fields via addDeploymentRefFields
- commit_comment without a commit id uses title_plain (no dangling ???????)
- tag pushes now report 'Tag created'; zh push title includes the {ref}
- sender profile link derives from the repo's forge origin instead of github.com
- group webhook log emoji injected via emojiPrefix, removed from locale files
- dispatchEvent accepts preloaded groups (single KV read per webhook)
- webhook 401 logs distinguish 'secret not configured' from 'invalid signature'
2026-08-14 07:41:19 +08:00
RhenCloud dfb65ef70d fix: link only the repo head in message titles, keep the subject plain 2026-08-13 19:18:55 +08:00
RhenCloud b139712a91 feat: migrate to Nuxt 4 (Nitro) and Tailwind CSS v3 2026-08-13 17:43:33 +08:00