Skip to content

feat(protocol): add CoAP DELETE requests - #49

Open
Jason-Morcos wants to merge 2 commits into
QuiteYellow:mainfrom
Moballo-LLC:codex/coap-delete
Open

feat(protocol): add CoAP DELETE requests#49
Jason-Morcos wants to merge 2 commits into
QuiteYellow:mainfrom
Moballo-LLC:codex/coap-delete

Conversation

@Jason-Morcos

@Jason-Morcos Jason-Morcos commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add METHOD_DELETE and a public DtlsCoapSession.delete() request primitive
  • reuse feat(protocol): validate GET and POST request options #48 validation for paths, repeated queries, and ordered extension options
  • pace and recheck liveness before sending the confirmable empty-body request
  • register the request in the shared token/MID exchange registry and wait through _wait_live
  • return the same (code, payload) shape as GET and POST
  • clean both pending indices after response, reset, timeout, or reader failure

Scope

This is the second PY-09 slice. It adds the wire-level method only: resource selection, authorization policy, ownership transactions, response interpretation, and Block1 behavior are unchanged.

The implementation is restacked on the current shared-MID and #54 liveness substrate. A bare RST is matched by MID, a response dispatched just before reader teardown still wins, and no path returns with a stale token or MID registration.

The DELETE-only commit is 11391db.

Stack / merge order

  1. feat(protocol): validate GET and POST request options #48: validated query and extension options
  2. feat(protocol): add CoAP DELETE requests #49 (this PR): DELETE
  3. feat(protocol): add bounded Block1 POST uploads #50: bounded Block1 POST uploads

Merge #49 after #48. It no longer depends on the old #51 branch.

Validation

  • 465 SmartThings-Local tests against this exact head
  • all 1,730 LocalThings tests at b5e25d7 against this exact source tree
  • focused DELETE encoding, pacing, RST, timeout cleanup, reader-death, response/teardown race, validation, and API-contract coverage
  • current Home Assistant request behavior compared against the working integration; its 55 focused transport/resilience tests pass
  • bytecode compilation, diff checks, and share-safety checks
  • all eight GitHub jobs pass on this exact head, including Python 3.11-3.14, dependency-floor/latest, package, and share safety

@QuiteYellow

QuiteYellow commented Aug 21, 2026

Copy link
Copy Markdown
Owner

Not reviewed yet, same as #48. #56 holds the order.

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.

2 participants