fix(feishu): support progress message cleanup - #21754
Conversation
37fe9ab to
dcf571f
Compare
|
Rebased on current main ( |
|
The test CI failure is pre-existing on |
|
The test CI failure is pre-existing on |
|
Hi @Bartok9, thanks for tackling this! I noticed the I took a quick look and wanted to offer some help:
I recently worked on a related Feishu fix (#22969) and have the dev environment set up. Happy to help debug the CI issues if you'd like — or I can hold off if you prefer to handle it yourself. Just let me know! cc @teknium1 for visibility on the CI status. |
dcf571f to
8525125
Compare
|
Hi @KhanCold — thanks for taking the time to look and for the offer to help debug! Really appreciated. I dug into both failures: ruff + ty diff: The 3 new test failures: I traced all the failing tests — they're unrelated to our changes:
I've rebased onto the latest Happy to add a |
|
CI note: The failing checks ( |
Co-authored-by: Cursor <cursoragent@cursor.com>
7f3fdce to
d5c6b41
Compare
|
Rebased onto current main. What I did:
Final diff: 2 files, +64 / -0 (additive only)
Verified both files compile cleanly under Python 3.14. Ready for review. 🎻 |
|
Closing to stay under the repo's 10-PR contributor limit. Will resubmit with updated code if the issue is still open in main. |
Problem
Feishu progress bubbles can remain visible after the final reply even when
display.platforms.feishu.cleanup_progress: trueis configured. Users then see stale edited progress messages, including duplicated(Edited)labels.Fixes #21746
Root cause
The gateway only enables progress cleanup for adapters that override
BasePlatformAdapter.delete_message. Feishu already supports progress updates throughedit_message(), but the adapter never implementeddelete_message(), so cleanup was disabled before it could delete temporary progress bubbles.Fix
Implement
FeishuAdapter.delete_message()using the Lark/Feishu message delete API path (client.im.v1.message.delete). A small request-builder helper mirrors the existing get/update/create request helpers and keeps tests working whenlark-oapiis unavailable.Testing
uv run --with pytest --with pytest-asyncio --with pytest-xdist --python 3.11 pytest tests/gateway/test_feishu.py -q -k 'edit_message or delete_message'uv run --with ruff --python 3.11 ruff check gateway/platforms/feishu.py tests/gateway/test_feishu.pyMade with Cursor