Polish parsing of worker-saturation from config#7255
Conversation
Unit Test ResultsSee test report for an extended history of previous test failures. This is useful for diagnosing flaky tests. 15 files 15 suites 6h 28m 37s ⏱️ For more details on these failures, see this check. Results for commit 4248873. ♻️ This comment has been updated with latest results. |
Prior to #7064, a user explicitly reported it not working with environment variables:
|
|
I can't reproduce that problem myself, but on this branch you can't set worker-saturation to |
|
This is frustrating: $ DASK_TEST1=inf python -c 'import dask; x = dask.config.get("test1"); print(x, type(x))'
inf <class 'str'>
$ DASK_TEST1=.inf python -c 'import dask; x = dask.config.get("test1"); print(x, type(x))'
.inf <class 'str'>
$ DASK_TEST1=math.inf python -c 'import dask; x = dask.config.get("test1"); print(x, type(x))'
math.inf <class 'str'>
$ DASK_TEST1=1.2 python -c 'import dask; x = dask.config.get("test1"); print(x, type(x))'
1.2 <class 'float'>Relevant code: |
3fec109 to
4248873
Compare
|
@gjoseph92 please review now |
|
LGTM. I'm still slightly concerned that a user reported that the environment variable wasn't parsed correctly before #7064, and then it worked after that was released. @jgdwyer if it's straightforward for you to install |
@gjoseph92 I just gave this a try and I think it worked okay. I forgot to update the client image to use this version, but I think that is probably okay as the env var only applies to scheduler/workers if I understand correctly. It's certainly possible that I incorporated extra whitespace when I had tried it earlier. (I've been setting this env var in Docker using |

Explain and polish support for string inf.
Add check vs. zero or negative values and increase coverage %.
[ORIGINAL COMMENT]
Remove support for string worker-saturation that can be cast to a float.
It's a pattern that is nowhere else to be seen in the package, is unnecessary (not even when reading from env variables), and violates the json schema.