Skip to content

fix(update_post): support the tags field (no version bump)#90

Merged
ColonistOne merged 1 commit into
mainfrom
fix/update-post-tags
Jul 11, 2026
Merged

fix(update_post): support the tags field (no version bump)#90
ColonistOne merged 1 commit into
mainfrom
fix/update-post-tags

Conversation

@ColonistOne

Copy link
Copy Markdown
Collaborator

Follow-up to #89. While testing get_suggestions() end-to-end, the tag_own_post suggestion couldn't be executed via its stated sdk_method: it returns update_post(post_id=…, tags=[…]), but update_post() only sent title/body — so client.update_post(post_id, tags=[…]) raised TypeError.

The API already supports it — I verified live that PUT /posts/{id} with a tags body sets the post's tags (created a throwaway post in test-posts, tagged it, confirmed persistence, deleted it). The SDK method just didn't expose the field.

Change: add an optional tags: list[str] | None = None to update_post() on ColonyClient, AsyncColonyClient, and MockColonyClient; include it in the PUT body when set. Same 15-minute edit window as title/body. +1 test (test_update_post_tags); verified end-to-end against the live API.

No version bump — rides in the unreleased 1.25.0, per the ask. Non-breaking, additive. Noted in the existing 1.25.0 CHANGELOG entry.

(The follow_user/join_colony sdk_args mismatches I also found are endpoint-side, not SDK — flagging those to arch-colony separately.)

🤖 Generated with Claude Code

The API accepts a tags list on PUT /posts/{id} (verified live), but
update_post() only sent title/body — so an agent following the
get_suggestions() tag_own_post suggestion (sdk_method=update_post,
sdk_args={post_id, tags}) got a TypeError. Add an optional tags param to
update_post on ColonyClient, AsyncColonyClient, and MockColonyClient;
same 15-minute edit window as title/body. +1 test; verified end-to-end
against the live API. Rides in the unreleased 1.25.0 — no version bump.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TRn9SBFGaxRwZbwRsKNJ7b
@ColonistOne ColonistOne merged commit 2724b4f into main Jul 11, 2026
6 checks passed
@ColonistOne ColonistOne deleted the fix/update-post-tags branch July 11, 2026 07:05
@codecov

codecov Bot commented Jul 11, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 90.00000% with 1 line in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/colony_sdk/async_client.py 75.00% 1 Missing ⚠️

📢 Thoughts on this report? Let us know!

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