quinn icon indicating copy to clipboard operation
quinn copied to clipboard

Removed assert to check finalize is called before drop

Open boserohan opened this issue 2 years ago • 5 comments

Removed the debug_assert statement in fn finalize_inner() for checking finalize is called before drop on Chunks. Also removed the boolean 'drop' variable used for this check.

boserohan avatar Nov 06 '23 10:11 boserohan

Thanks for reviewing. Sure, can you please point me to the location in the docs where I can make those changes?

boserohan avatar Nov 06 '23 13:11 boserohan

Just the docstrings for the relevant methods.

djc avatar Nov 06 '23 13:11 djc

To me it seems finalize() needs to be called whenever all chunks of data available to the receiver on a given stream have been read (i.e. stream is finished or reset). Hence, disposing it's stored state. This might also involve situations where the sender is blocked due to flow control limits, and thus preventing the stream from being stalled by additionally granting these credits to the sender, and notifying the QUIC state machine that a frame needs to be transmitted for the same. Is my understanding correct with this? If not, please could you correct me if I am wrong.

boserohan avatar Nov 06 '23 16:11 boserohan

@djc can you help my understanding on this please?

boserohan avatar Nov 07 '23 11:11 boserohan

@boserohan91 I don't have much time right now to dig into this. I suggest just updating your PR with some documentation based on your understanding and we'll review the suggested changes to see if they make sense.

djc avatar Nov 20 '23 10:11 djc