bw2 / ConfigArgParse

A drop-in replacement for argparse that allows options to also be set via config files and/or environment variables.
MIT License
722 stars 121 forks source link

Handle different argparse output in Python 3.10 #226

Closed major closed 3 years ago

major commented 3 years ago

In Python 3.10, argparse uses options: instead of optional arguments:, and this broke some of the tests.

Add a condition to check the Python version and look for options: in the argparse output if the Python version is 3.10 or higher.

Fixes bw2/ConfigArgParse#225

Signed-off-by: Major Hayden major@mhtx.net

bw2 commented 3 years ago

Thanks for the PR!