Repository navigation
set mp start method to spawn - #38
Conversation
ca9989a to
b8ea6ed
Compare
b8ea6ed to
808eff1
Compare
abradley60
left a comment
There was a problem hiding this comment.
Looks good thanks Amir! Just a couple q's/comments
|
|
||
| [tool.pytest.ini_options] | ||
| testpaths = ["tests/*"] | ||
| filterwarnings = [ |
There was a problem hiding this comment.
Does the warning filter need to be added with the fix?
There was a problem hiding this comment.
Yes, for some reason urlib3 which I don't know where it is being used :D will complain about another package it is importing that is enabling the global lock (GIL) for Python versions that disable it (i.e. python 3.13t or 3.14t) so I suppressed the warning in the pytest configs.
There was a problem hiding this comment.
Unless we don't want to care about the warning.
There was a problem hiding this comment.
IMO I'm not too fussed about the warning, but if you and Caitlin want to suppress cool w me!
| import boto3 | ||
| import numpy as np | ||
| import rasterio | ||
| import rasterio.profiles |
There was a problem hiding this comment.
Can see a few imports have changed. Just confirming these are all not required
There was a problem hiding this comment.
Yes I removed the unused imports
caitlinadams
left a comment
There was a problem hiding this comment.
Looks good to me, thank you!
Python 3.12+ warns about deadlocks when the parent process running multiple threads calls an os.fork(). A fix is setting the start method to
spawnso it creates a clean copy on python interpreter at the cost of slower start. However, as we create out workers once then the impact should not be significant.