mirror of
https://github.com/Instagram/LibCST.git
synced 2025-12-23 10:35:53 +00:00
Support <3.7
This commit is contained in:
parent
dc782f116a
commit
834b5b989e
1 changed files with 5 additions and 3 deletions
|
|
@ -756,11 +756,13 @@ def parallel_exec_transform_with_prettyprint( # noqa: C901
|
|||
skips += 1
|
||||
|
||||
warnings += len(result.transform_result.warning_messages)
|
||||
process = filename_to_process.get(result.filename)
|
||||
|
||||
# Join the process to free any related resources.
|
||||
# Remove all references to the process to allow the GC to
|
||||
# clean up any file handles.
|
||||
process = filename_to_process.pop(result.filename, None)
|
||||
if process:
|
||||
# Join and close the process to free any related file handles.
|
||||
process.join()
|
||||
process.close()
|
||||
if process in joinable_processes:
|
||||
joinable_processes.remove(process)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue