Per a discussion on Membrane's Discord, the InputQueue can overwrite demands and may only request a smaller size than specified. To avoid runtime errors when this happens, we now collect the binary buffers and submit them only once we meet the AWS minimum size.
The tests cover the pre split and post split scenarios, although it would probably be a good idea to add another test to cover the final upload chunk that will now happen when the chunks are uploaded at the end of the stream.
Per a discussion on Membrane's Discord, the InputQueue can overwrite demands and may only request a smaller size than specified. To avoid runtime errors when this happens, we now collect the binary buffers and submit them only once we meet the AWS minimum size.
The tests cover the pre split and post split scenarios, although it would probably be a good idea to add another test to cover the final upload chunk that will now happen when the chunks are uploaded at the end of the stream.