Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Cosmetics

  • Loading branch information...
commit 18a4c159a63f5954653563414612754014afa3ec 1 parent 16c84d2
@vmalloc authored
Showing with 12 additions and 4 deletions.
  1. +7 −3 pydeploy/environment.py
  2. +5 −1 pydeploy/installer.py
View
10 pydeploy/environment.py
@@ -123,12 +123,16 @@ def _is_url(self, path_or_url):
return bool(urlparse(path_or_url).scheme)
def _make_source_object(self, source):
if isinstance(source, pkg_resources.Requirement):
- if source.specs:
- raise NotImplementedError() # pragma: no cover
+ specs = source.specs
source = source.unsafe_name
+ else:
+ specs = []
+ if specs:
+ raise NotImplementedError("Installing from specs not supported (for {0})".format(source))
if isinstance(source, basestring) and source in self._aliases:
source = self._aliases[source]
- return Source.from_anything(source)
+ source = Source.from_anything(source)
+ return source
def _post_install(self, source):
raise NotImplementedError() # pragma: no cover
View
6 pydeploy/installer.py
@@ -1,10 +1,13 @@
-import sys
+import logging
import os
+import sys
import tempfile
import zipfile
from .command import execute_assert_success
from pkg_resources import parse_requirements
+_logger = logging.getLogger("pydeploy.installer")
+
class Installer(object):
def __init__(self, env):
super(Installer, self).__init__()
@@ -20,6 +23,7 @@ def _run_pydeploy_setup(self, path):
def _install_requirements(self, path):
for req in self._get_install_requirements(path):
if self._env.has_alias(req):
+ _logger.info("Package depends on %s which can be installed through an alias. Installing...", req)
self._env.install(req)
def _get_install_requirements(self, path):
temp_dir = tempfile.mkdtemp()
Please sign in to comment.
Something went wrong with that request. Please try again.