Convert parallel setting to int - #9869
Open
radarhere wants to merge 1 commit into
Open
Conversation
hugovk
reviewed
Aug 12, 2026
Comment on lines
+383
to
+384
| if "parallel" in configuration: | ||
| self.parallel = int(configuration["parallel"][-1]) |
Member
There was a problem hiding this comment.
Likely caused by today's https://pypi.org/project/types-setuptools/84.0.0.20260812/
We already have this value at:
Line 35 in a9fd14b
Shall we rename that to something like parallel_default and:
Suggested change
| if "parallel" in configuration: | |
| self.parallel = int(configuration["parallel"][-1]) | |
| self.parallel = parallel_default |
Or use the same pattern as there:
Suggested change
| if "parallel" in configuration: | |
| self.parallel = int(configuration["parallel"][-1]) | |
| self.parallel = int(configuration.get("parallel", ["0"])[-1]) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
LInt has started failing - https://github.com/python-pillow/Pillow/actions/runs/31563474566/job/94010414409#step:6:22
setup.py:383: error: Incompatible types in assignment (expression has type "str | None", variable has type "int | None") [assignment] self.parallel = configuration.get("parallel", [None])[-1] ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Found 1 error in 1 file (checked 303 source files)