Skip to content

Clarify StreamExt::timeout() docs #800

Open
@Seeker14491

Description

@Seeker14491

The description for StreamExt::timeout() states it will "await a stream or times out after a duration of time," but it's not clear whether it times out after the specified duration

  1. since calling timeout()

or

  1. since a stream item was last produced

I wanted #2 when I used this function, but then I realized it actually works like #1.

I noticed theres a pull request that adds a timeout_repeat() function that implements #2; the docs on both these functions should make it clear which of the above behaviors it implements.

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentationImprovements or additions to documentation

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions