Skip to content

Commit

Permalink
Simplified extras_require in setup.py (#277)
Browse files Browse the repository at this point in the history
Before, we used ternary operations on lists in Python code of 
`setup.py` to conditionally add development dependencies based on
the Python version.

In this patch, we replaced this code with requirements specifiers,
which substantially simplified the code in `setup.py`.
  • Loading branch information
jruere committed Oct 4, 2023
1 parent a976e61 commit 4c8b235
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,11 @@
"typeguard>=2,<3",
"astor==0.8.1",
"numpy>=1,<2",
'mypy==1.5.1;python_version>="3.8"',
'black==23.9.1;python_version>="3.8"',
'deal==4.23.3;python_version>"=3.8"',
'asyncstdlib==3.9.1;python_version>="3.8"',
]
+ (["mypy==1.5.1"] if sys.version_info >= (3, 8) else [])
+ (["black==23.9.1"] if sys.version_info >= (3, 8) else [])
+ (["deal==4.23.3"] if sys.version_info >= (3, 8) else [])
+ (["asyncstdlib==3.9.1"] if sys.version_info >= (3, 8) else []),
},
py_modules=["icontract"],
package_data={"icontract": ["py.typed"]},
Expand Down

0 comments on commit 4c8b235

Please sign in to comment.