project-chip / connectedhomeip

Matter (formerly Project CHIP) creates more connections between more objects, simplifying development for manufacturers and increasing compatibility for consumers, guided by the Connectivity Standards Alliance.
https://buildwithmatter.com
Apache License 2.0
7.55k stars 2.03k forks source link

If no attribute and event data encoded successfully, we should send status report instead of drop out #14566

Open yunhanw-google opened 2 years ago

yunhanw-google commented 2 years ago

Context is from

_Originally posted by @bzbarsky-apple in https://github.com/project-chip/connectedhomeip/pull/13400#discussion_r794897876_

Fix the logic here if (!hasEncodedAttributes && !hasEncodedEvents && hasMoreChunks) { ChipLogError(DataManagement, "No data actually encoded but hasMoreChunks flag is set, abort report! (attribute too big?)"); ExitNow(err = CHIP_ERROR_INCORRECT_STATE); }

bzbarsky-apple commented 2 years ago

In particular, we should probably do a path-specific status for whatever path it was that did not fit in the packet.

bzbarsky-apple commented 2 years ago

RESOURCE_EXHAUSTED seems like a good status to use here.

woody-apple commented 2 years ago

Spec Review: @mrjerryjohns to review.

mrjerryjohns commented 2 years ago

Chatted with @bzbarsky-apple , punting for post v1.0 since it's not really needed, and adding more logic here may introduce more bugs than is worth.

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.