Skip to content

feat: add coalesce_id support for push and text services - #27

Merged
IngmarStein merged 2 commits into
mainfrom
feature/coalesce-id-support
Jun 9, 2026
Merged

IngmarStein merged 2 commits into
mainfrom
feature/coalesce-id-support

Conversation

@IngmarStein

Copy link
Copy Markdown
Member

Adds support for the Coalesce ID feature introduced in tronbyt/server#830.

What is Coalesce ID?

A coalesceID is an optional string identifier that clients can attach to push requests. When a new push arrives with a given coalesceID, the server deletes any existing ephemeral file with that same coalesceID before saving the new one — ensuring at most one pending push per coalesceID.

Changes

  • const.py: Added ATTR_COALESCE_ID constant
  • __init__.py:
    • Added validate_coalesce_id() function (validates max 64 chars, alphanumeric/underscore/dash only)
    • Updated handle_push_or_text() to extract optional coalesce_id from service call data and pass it as coalesceID in the push request body
  • services.yaml: Added coalesce_id text field to the advanced sections of both push and text services

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces support for a coalesce_id parameter in the push and text services of the tronbytassistant integration, allowing deduplication of anonymous pushes. It adds validation logic to ensure the ID is alphanumeric (including underscores and dashes) and under 64 characters, and forwards it in the API request body. The review feedback highlights a potential TypeError if coalesce_id is passed as a non-string type (such as an integer) and suggests coercing it to a string before validation to prevent runtime exceptions.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

@IngmarStein
IngmarStein requested a review from gabe565 June 7, 2026 21:12
@IngmarStein
IngmarStein merged commit af8e6ef into main Jun 9, 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.

1 participant