Skip to content

Conversation

@alextwoods
Copy link
Contributor

@alextwoods alextwoods commented Mar 10, 2025

Description of changes:
Previously the AsyncBytesProvider write was appending to a list and the async iter was pop'ing from the end of that list - effectively iterating through the chunks of data in reverse order.

This PR updates the AsyncBytesProvider to use a deque - write appends to it and the iterator uses popleft to return the fist item.

Also updates the existing test_provider_reads_written_data test to write multiple chunks of data. Test fails without this change (returning [bar, foo] instead of [foo, bar]) and now passes.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@alextwoods alextwoods requested a review from a team as a code owner March 10, 2025 23:37
Copy link
Contributor

@nateprewitt nateprewitt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@alextwoods alextwoods merged commit 6b80522 into smithy-lang:develop Mar 11, 2025
2 checks passed
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.

3 participants