Skip to content
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

Fix missing jobs arg for _initialize_populate in Pool #997

Merged
merged 2 commits into from
Mar 25, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion datajoint/autopopulate.py
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ def handler(signum, frame):
# spawn multiple processes
self.connection.close() # disconnect parent process from MySQL server
del self.connection._conn.ctx # SSLContext is not pickleable
with mp.Pool(processes, _initialize_populate, (self, populate_kwargs)) as pool:
with mp.Pool(processes, _initialize_populate, (self, jobs, populate_kwargs)) as pool:
if display_progress:
with tqdm(desc="Processes: ", total=nkeys) as pbar:
for error in pool.imap(_call_populate1, keys, chunksize=1):
Expand Down