Skip to content

feat: tea.Wait#722

Merged
caarlos0 merged 3 commits intomasterfrom
wait
May 4, 2023
Merged

feat: tea.Wait#722
caarlos0 merged 3 commits intomasterfrom
wait

Conversation

@caarlos0
Copy link
Copy Markdown
Contributor

wait for the underlying context to finish.

extract from #352

wait for the underlying context to finish.

extract from #352
@caarlos0 caarlos0 self-assigned this Apr 17, 2023
@caarlos0 caarlos0 added the enhancement New feature or request label Apr 17, 2023
@caarlos0 caarlos0 marked this pull request as ready for review April 17, 2023 14:46
Copy link
Copy Markdown
Member

@meowgorithm meowgorithm left a comment

Choose a reason for hiding this comment

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

Per my chat with @muesli, it would be awesome if Wait() could return after the terminal state has been restored (internally, at the end of Program.shutdown).

Signed-off-by: Carlos Alexandro Becker <caarlos0@users.noreply.github.com>
@caarlos0
Copy link
Copy Markdown
Contributor Author

ah, I actually don't even need this, I can pass my own context with WithContext.

as per your request, pushed something I think will help

Copy link
Copy Markdown
Member

@meowgorithm meowgorithm left a comment

Choose a reason for hiding this comment

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

Nice! This is exactly how I solved for it in #726 — except your API design's much better.

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

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants