summary refs log tree commit diff stats
path: root/ganarchy/cli
diff options
context:
space:
mode:
authorSoniEx2 <endermoneymod@gmail.com>2022-01-20 20:45:16 -0300
committerSoniEx2 <endermoneymod@gmail.com>2022-01-20 20:45:16 -0300
commita51c18000cdf4e623d4a46246bcc6d5b1f47e917 (patch)
treec55dd8e36924f9258c9d85f22b4b230be3062896 /ganarchy/cli
parente205879303c2aaeb9ea1a537ce3a8145ebe6fce0 (diff)
Fix data race
Diffstat (limited to 'ganarchy/cli')
-rw-r--r--ganarchy/cli/run_targets.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/ganarchy/cli/run_targets.py b/ganarchy/cli/run_targets.py
index 53e1b0f..eb3fb0c 100644
--- a/ganarchy/cli/run_targets.py
+++ b/ganarchy/cli/run_targets.py
@@ -141,7 +141,7 @@ def run_once(out, n_threads, keep_stale_projects):
     with core.GIT.with_work_repos(n_threads) as work_repos:
         threads = []
         for i, work_repo in enumerate(work_repos):
-            t = threading.Thread(target=lambda: run_thread(i, work_repo), name="ganarchy-fetch-{}".format(i))
+            t = threading.Thread(target=lambda i=i, work_repo=work_repo: run_thread(i, work_repo), name="ganarchy-fetch-{}".format(i))
             t.start()
             threads.append(t)
         for t in threads: