Skip to content

Commit

Permalink
Fix parsing requirements in setup.py (#1075)
Browse files Browse the repository at this point in the history
  • Loading branch information
JonnyWong16 authored Dec 21, 2022
1 parent f330d87 commit 73f8a8b
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"""
Install PlexAPI
"""
from pkg_resources import parse_requirements
try:
from setuptools import setup
except ImportError:
Expand All @@ -14,12 +15,8 @@
readme = open('README.rst', 'r').read()

# Get requirements
requirements = []
with open('requirements.txt') as handle:
for line in handle.readlines():
if not line.startswith('#'):
package = line.strip().split('=', 1)[0]
requirements.append(package)
requirements = [str(req) for req in parse_requirements(handle)]

setup(
name='PlexAPI',
Expand Down

0 comments on commit 73f8a8b

Please sign in to comment.