projects
/
archive
/
20170607
/
tools
/
tic-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
[TIC-CORE] Logger support and add test-cast for repodata
[archive/20170607/tools/tic-core.git]
/
tic
/
utils
/
process.py
diff --git
a/tic/utils/process.py
b/tic/utils/process.py
index
7d02125
..
8fe75cb
100644
(file)
--- a/
tic/utils/process.py
+++ b/
tic/utils/process.py
@@
-20,10
+20,12
@@
# - S-Core Co., Ltd
import subprocess
# - S-Core Co., Ltd
import subprocess
+import logging
from tic.utils.error import TICError
def run(cmdln):
from tic.utils.error import TICError
def run(cmdln):
+ logger = logging.getLogger()
if isinstance(cmdln, list):
cmd = cmdln[0]
shellType = False
if isinstance(cmdln, list):
cmd = cmdln[0]
shellType = False
@@
-39,6
+41,7
@@
def run(cmdln):
shell=shellType)
(sout, serr) = p.communicate()
out = ''.join(filter(None, [sout, serr]))
shell=shellType)
(sout, serr) = p.communicate()
out = ''.join(filter(None, [sout, serr]))
+ logger.info('subprocess open: %s', cmd)
except OSError as e:
if e.errno == 2:
# No such file or directory
except OSError as e:
if e.errno == 2:
# No such file or directory