Skip to content

Commit

Permalink
update python_min format
Browse files Browse the repository at this point in the history
Co-authored-by: Filipe <[email protected]>
  • Loading branch information
marcelotrevisani and ocefpaf committed Nov 13, 2024
1 parent 735d83f commit f72f665
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions grayskull/strategy/pypi.py
Original file line number Diff line number Diff line change
Expand Up @@ -590,9 +590,9 @@ def set_python_min(req_list: list, section: str) -> list:
return req_list
python_min = "<{ python_min }}"
map_section = {
"host": f"{python_min}.*",
"host": f"{python_min}",
"run": f">={python_min}",
"test": f"={python_min}",
"test": f"{python_min}",
}
return [
f"python {map_section[section]}" if dep.lower().strip() == "python" else dep
Expand Down
4 changes: 2 additions & 2 deletions tests/test_pypi.py
Original file line number Diff line number Diff line change
Expand Up @@ -1459,9 +1459,9 @@ def test_check_noarch_python_for_new_deps():
@pytest.mark.parametrize(
"section, expected",
[
("host", "python <{ python_min }}.*"),
("host", "python <{ python_min }}"),
("run", "python >=<{ python_min }}"),
("test", "python =<{ python_min }}"),
("test", "python <{ python_min }}"),
],
)
def test_set_python_min(section, expected):
Expand Down

0 comments on commit f72f665

Please sign in to comment.