Skip to content

Commit

Permalink
Merge pull request #198 from marcelotrevisani/fix-194-empty-entry_points
Browse files Browse the repository at this point in the history
Fix 194 empty entry points
  • Loading branch information
marcelotrevisani authored Oct 18, 2020
2 parents 5af537c + 1ff9005 commit f754972
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion grayskull/pypi/pypi.py
Original file line number Diff line number Diff line change
Expand Up @@ -466,7 +466,7 @@ def _get_entry_points_from_sdist(sdist_metadata: dict) -> List:
return_entry_point = []
for entry_point in entry_points_result:
return_entry_point.extend(entry_point.split("\n"))
return return_entry_point
return [ep for ep in return_entry_point if ep.strip()]
return []

@staticmethod
Expand Down
5 changes: 5 additions & 0 deletions tests/test_pypi.py
Original file line number Diff line number Diff line change
Expand Up @@ -645,3 +645,8 @@ def test_clean_deps_for_conda_forge():
"deps1",
"deps2 # [py<38]",
]


def test_empty_entry_points():
recipe = PyPi(name="modulegraph", version="0.18")
assert recipe["build"]["entry_points"] == "modulegraph = modulegraph.__main__:main"

0 comments on commit f754972

Please sign in to comment.