Commit ff70b8b7 authored by Xiaowu Zhang's avatar Xiaowu Zhang

use corretly log function

parent 7eca74fe
...@@ -73,7 +73,7 @@ class Recipe(object): ...@@ -73,7 +73,7 @@ class Recipe(object):
m.update(option_signature) m.update(option_signature)
shared = os.path.join(shared, m.hexdigest()) shared = os.path.join(shared, m.hexdigest())
self._parts = parts = shared self._parts = parts = shared
log.info('shared directory %s set for %s' % (shared, name)) log.info('shared directory %s set for %s', shared, name)
else: else:
self._parts = parts = os.path.join(buildout_section['parts-directory'], self._parts = parts = os.path.join(buildout_section['parts-directory'],
name) name)
...@@ -89,7 +89,7 @@ class Recipe(object): ...@@ -89,7 +89,7 @@ class Recipe(object):
parts = self._parts parts = self._parts
log = logging.getLogger(self._name) log = logging.getLogger(self._name)
if self._shared: if self._shared:
log.info('Checking whether package is installed at shared path: %s' % destination) log.info('Checking whether package is installed at shared path: %s', destination)
if os.path.exists(destination): if os.path.exists(destination):
log.info('This shared package has been installed by other package') log.info('This shared package has been installed by other package')
return [] return []
......
...@@ -70,7 +70,7 @@ class Recipe: ...@@ -70,7 +70,7 @@ class Recipe:
m.update(option_signature) m.update(option_signature)
shared = os.path.join(shared, m.hexdigest()) shared = os.path.join(shared, m.hexdigest())
self.parts = shared self.parts = shared
self.logger.info('shared directory %s set for %s' % (shared, name)) self.logger.info('shared directory %s set for %s', shared, name)
else: else:
self.parts = os.path.join(self.buildout['buildout']['parts-directory'], self.parts = os.path.join(self.buildout['buildout']['parts-directory'],
self.name) self.name)
...@@ -100,7 +100,7 @@ class Recipe: ...@@ -100,7 +100,7 @@ class Recipe:
def install(self): def install(self):
if self.shared: if self.shared:
self.logger.info('Checking whether package is installed at shared path : %s' % self.destination) self.logger.info('Checking whether package is installed at shared path : %s', self.destination)
if os.path.exists(self.destination): if os.path.exists(self.destination):
self.logger.info('This shared package has been installed by other package') self.logger.info('This shared package has been installed by other package')
return [] return []
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment