8000 Scope the lifetime of the worker pool created during options parsing by elliottt · Pull Request #8860 · sorbet/sorbet · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Scope the lifetime of the worker pool created during options parsing #8860

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 9, 2025

Conversation

elliottt
Copy link
Collaborator
@elliottt elliottt commented May 9, 2025

The WorkerPool created during options parsing lives only long enough to parallelize input file discovery, but the pool sticks around for the remainder of option parsing. Let's clean it up when we're done with it instead.

Hiding whitespace changes should make it pretty obvious that this change is pretty simple: I just wrapped curly braces around the region where the WorkerPool is used.

Motivation

Releasing resources sooner.

Test plan

Existing tests.

@elliottt elliottt marked this pull request as ready for review May 9, 2025 22:42
@elliottt elliottt requested a review from a team as a code owner May 9, 2025 22:42
@elliottt elliottt requested review from neilparikh and removed request for a team May 9, 2025 22:42
@elliottt elliottt merged commit 1702868 into master May 9, 2025
14 checks passed
@elliottt elliottt deleted the trevor/scope-options-worker-pool branch May 9, 2025 23:11
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.

2 participants
0