Skip to content

Refactor read operation algorithm #208

Open

Description

@gterzian

The read operation algorithm uses the inappropriate "in parallel" concept(see event-loop-for-spec-authors), and instead of rewording this, it could be simplified through the use ofreadablestreamdefaultreader-read-all-bytes.

Here is an example from Fetch.

Activity

  1. gterzian commented on Mar 14, 2025

    @gterzian
    Author

    Actually I just realized read_all_bytes does not have a hook for running an operation for each chunk, which means it cannot be used to fire the progress event...

    So instead the spec could follow the more convoluted Fetch example of incrementally-read-loop

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions