block / block/builder-syndicate

feat(posts): add digest field to UpdatePostRequest for idempotent updates

Open
#34 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Kotlin
Stars
6
Forks
4
PR merge metrics
No merged PRs in 30d

Description

## Summary

Add a `digest` field to `UpdatePostRequest` so the server can reject stale updates (debouncing). The digest is a lightweight hash (CRC32 or MD5) of the post content — no cryptographic security needed.

## Acceptance Criteria

- User can submit an update with a digest of the content they based their edit on
- Server rejects the update if the digest doesn't match the current post content (409 Conflict)
- Digest algorithm is simple (CRC32 or similar) — not cryptographically secure
- Digest field is optional for backward compatibility

## Context

From PR #31 review feedback on `posts.proto`.

Contributor guide

Open the contributing guide

Research direction

Start with posts.proto and locate UpdatePostRequest and the server path that handles post updates. Trace how the current post content is compared, then verify the optional digest, mismatch response, backward compatibility, and 409 Conflict behavior against the acceptance criteria.

Written by the indexing model from the issue text.

Assessment

Tech stack
kotlin
Domain
api, backend
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.