Merge pull request #155 from ros/backports_kinetic
changes between 1.13.5 and 1.14.2 for backporting
This commit is contained in:
commit
816ffda9d6
|
@ -249,7 +249,7 @@ function rosed {
|
|||
if [[ -z $EDITOR ]]; then
|
||||
vim ${arg}
|
||||
else
|
||||
$EDITOR ${arg}
|
||||
eval $EDITOR ${arg}
|
||||
fi
|
||||
}
|
||||
|
||||
|
@ -747,7 +747,7 @@ compctl -K "_roscomplete_rosmake" "rosmake"
|
|||
compctl -x 'p[1]' -k "(check purge)" -- "rosclean"
|
||||
compctl -f -x 'p[1]' -K "_roscomplete" - 'p[2]' -K _roscomplete_file -- "rosed" "roscp" "roscat"
|
||||
compctl -f -x 'S[-]' -k '(--debug --prefix)' - 'c[-1,--prefix][-1,-p]' -h '' - 'p[1],c[-1,-d],c[-1,--debug],c[-2,-p],c[-2,--prefix]' -K "_roscomplete" - 'p[2],c[-2,-d],c[-2,--debug],c[-3,-p],c[-3,--prefix]' -K _roscomplete_exe -- "rosrun"
|
||||
compctl -/g '*.(launch|test)' -x 'p[1]' -K "_roscomplete" -tx - 'p[2]' -K _roscomplete_launchfile -- + -x 'S[--]' -k "(--files --args --nodes --find-node --child --local --screen --server_uri --run_id --wait --port --core --pid --dump-params)" -- "roslaunch"
|
||||
compctl -/g '*.(launch|test)' -x 'p[1]' -K "_roscomplete" -tx - 'p[2]' -K _roscomplete_launchfile -- + -x 'S[--]' -k "(--files --args --nodes --find-node --child --local --screen --server_uri --run_id --wait --port --core --pid --dump-params --disable-title --help --numworkers --ros-args --skip-log-check --timeout)" -- "roslaunch"
|
||||
compctl -/g '*.(launch|test)' -x 'p[1]' -K "_roscomplete" -tx - 'p[2]' -K _roscomplete_launchfile -- + -x 'S[--]' -k "(--bare --bare-limit --bare-name --pkgdir --package)" -- "rostest"
|
||||
compctl -K "_roscomplete_rospack" "rospack"
|
||||
compctl -K "_roscomplete_rosbag" + -g "*.bag *(/)" "rosbag"
|
||||
|
|
|
@ -320,6 +320,12 @@ class LocalProcess(pmon.Process):
|
|||
cwd = get_ros_root()
|
||||
else:
|
||||
cwd = rospkg.get_ros_home()
|
||||
if not os.path.exists(cwd):
|
||||
try:
|
||||
os.makedirs(cwd)
|
||||
except OSError:
|
||||
# exist_ok=True
|
||||
pass
|
||||
|
||||
try:
|
||||
self.popen = subprocess.Popen(self.args, cwd=cwd, stdout=logfileout, stderr=logfileerr, env=full_env, close_fds=True, preexec_fn=os.setsid)
|
||||
|
|
|
@ -39,12 +39,15 @@ Library for reading and manipulating Ant JUnit XML result files.
|
|||
|
||||
from __future__ import print_function
|
||||
|
||||
import codecs
|
||||
import os
|
||||
import sys
|
||||
try:
|
||||
from cStringIO import StringIO
|
||||
python2 = True
|
||||
except ImportError:
|
||||
from io import StringIO
|
||||
python2 = False
|
||||
import string
|
||||
import codecs
|
||||
import re
|
||||
|
@ -56,7 +59,14 @@ from xml.dom import Node as DomNode
|
|||
from functools import reduce
|
||||
import rospkg
|
||||
|
||||
invalid_chars = re.compile(ur'[^\x09\x0A\x0D\x20-\x7E\x85\xA0-\xFF\u0100-\uD7FF\uE000-\uFDCF\uFDE0-\uFFFD]')
|
||||
pattern = r'[^\x09\x0A\x0D\x20-\x7E\x85\xA0-\xFF\u0100-\uD7FF\uE000-\uFDCF\uFDE0-\uFFFD]'
|
||||
if python2:
|
||||
pattern = pattern.decode('unicode_escape')
|
||||
else:
|
||||
pattern = codecs.decode(pattern, 'unicode_escape')
|
||||
invalid_chars = re.compile(pattern)
|
||||
|
||||
|
||||
def invalid_char_replacer(m):
|
||||
return "&#x"+('%04X' % ord(m.group(0)))+";"
|
||||
def filter_nonprintable_text(text):
|
||||
|
|
|
@ -9,6 +9,7 @@ from __future__ import print_function
|
|||
|
||||
__revision__ = "$Id$"
|
||||
|
||||
import codecs
|
||||
import os.path
|
||||
import re
|
||||
import sys
|
||||
|
@ -17,8 +18,10 @@ import traceback
|
|||
import unittest
|
||||
try:
|
||||
from cStringIO import StringIO
|
||||
python2 = True
|
||||
except ImportError:
|
||||
from io import StringIO
|
||||
python2 = False
|
||||
from xml.sax.saxutils import escape
|
||||
import xml.etree.ElementTree as ET
|
||||
|
||||
|
@ -86,7 +89,7 @@ class _TestInfo(object):
|
|||
# "method": self._method,
|
||||
# "time": self._time,
|
||||
# })
|
||||
stream.write(self._method)
|
||||
stream.write('[Testcase: ' + self._method + ']')
|
||||
if self._failure != None:
|
||||
stream.write(' ... FAILURE!\n')
|
||||
self._print_error_text(stream, 'failure', self._failure)
|
||||
|
@ -159,7 +162,13 @@ class _XMLTestResult(unittest.TestResult):
|
|||
self._failure = err
|
||||
|
||||
def filter_nonprintable_text(self, text):
|
||||
invalid_chars = re.compile(ur'[^\x09\x0A\x0D\x20-\x7E\x85\xA0-\xFF\u0100-\uD7FF\uE000-\uFDCF\uFDE0-\uFFFD]')
|
||||
pattern = r'[^\x09\x0A\x0D\x20-\x7E\x85\xA0-\xFF\u0100-\uD7FF\uE000-\uFDCF\uFDE0-\uFFFD]'
|
||||
if python2:
|
||||
pattern = pattern.decode('unicode_escape')
|
||||
else:
|
||||
pattern = codecs.decode(pattern, 'unicode_escape')
|
||||
invalid_chars = re.compile(pattern)
|
||||
|
||||
def invalid_char_replacer(m):
|
||||
return "&#x"+('%04X' % ord(m.group(0)))+";"
|
||||
return re.sub(invalid_chars, invalid_char_replacer, str(text))
|
||||
|
|
Loading…
Reference in New Issue