Skip to content

Commit

Permalink
fix: translate path-py to path.py in setup.py
Browse files Browse the repository at this point in the history
  • Loading branch information
matfax committed Oct 17, 2019
1 parent 914ab79 commit 2732b47
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import json
from pathlib import Path
from typing import List

from setuptools import setup, find_packages

Expand All @@ -8,7 +9,13 @@ def get_dependencies(pipfile_lock=None):
if pipfile_lock is None:
pipfile_lock = Path("Pipfile.lock")
lock_data = json.load(pipfile_lock.open())
return [package_name for package_name in lock_data.get('default', {}).keys()]
result: List[str] = [package_name for package_name in lock_data.get('default', {}).keys()]
for k in result:
if "path-py" in k:
new_key = k.replace("path-py", "path.py")
result.remove(k)
result.append(new_key)
return result


setup(
Expand All @@ -34,4 +41,5 @@ def get_dependencies(pipfile_lock=None):
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
],
python_requires=">=3.7"
)

0 comments on commit 2732b47

Please sign in to comment.