No need to run pip install pyScss in setup.py if it's not available

This commit is contained in:
Fabio Manganiello 2019-12-02 00:24:28 +01:00
parent 526136be36
commit fbe4f9494c
2 changed files with 8 additions and 15 deletions

View file

@ -3,8 +3,6 @@
import errno
import os
import re
import subprocess
import sys
import distutils.cmd
from distutils.command.build import build
from setuptools import setup, find_packages
@ -23,15 +21,9 @@ class WebBuildCommand(distutils.cmd.Command):
try:
from scss import Compiler
except ImportError:
print('pyScss not found, trying to install it')
cmd = [sys.executable, '-m', 'pip', 'install', 'pyScss']
try:
subprocess.call(cmd)
except Exception as e:
print(('pyScss install command failed: {}: {}. You will have to generate ' +
'the CSS files manually through python setup.py build install').format(' '.join(cmd), str(e)))
return
print('pyScss module not found: {}. You will have to generate ' +
'the CSS files manually through python setup.py build install')
return
print('Building CSS files')
base_path = path(os.path.join('platypush','backend','http','static','css'))