[genpy] 01/01: Imported Upstream version 0.5.6
Jochen Sprickerhof
jspricke-guest at moszumanska.debian.org
Tue Oct 13 10:11:20 UTC 2015
This is an automated email from the git hooks/post-receive script.
jspricke-guest pushed a commit to annotated tag upstream/0.5.6
in repository genpy.
commit b407907dbf4f53140b413b7a630c57864c9bf533
Author: Jochen Sprickerhof <git at jochen.sprickerhof.de>
Date: Tue Oct 13 12:09:57 2015 +0200
Imported Upstream version 0.5.6
---
CHANGELOG.rst | 4 ++++
package.xml | 2 +-
src/genpy/dynamic.py | 3 ++-
3 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/CHANGELOG.rst b/CHANGELOG.rst
index 6f431ab..6ab5ca2 100644
--- a/CHANGELOG.rst
+++ b/CHANGELOG.rst
@@ -2,6 +2,10 @@
Changelog for package genpy
^^^^^^^^^^^^^^^^^^^^^^^^^^^
+0.5.6 (2015-10-12)
+------------------
+* fix handling of dynamic message classes with names containing other message classes as substrings (`#40 <https://github.com/ros/genpy/pull/40>`_)
+
0.5.5 (2015-09-19)
------------------
* fix handling of dynamic message classes with the same name (`#37 <https://github.com/ros/genpy/issues/37>`_)
diff --git a/package.xml b/package.xml
index bb66ff8..89edb4c 100644
--- a/package.xml
+++ b/package.xml
@@ -1,7 +1,7 @@
<?xml version="1.0"?>
<package>
<name>genpy</name>
- <version>0.5.5</version>
+ <version>0.5.6</version>
<description>Python ROS message and service generators.</description>
<maintainer email="dthomas at osrfoundation.org">Dirk Thomas</maintainer>
<license>BSD</license>
diff --git a/src/genpy/dynamic.py b/src/genpy/dynamic.py
index 22c25e9..e453310 100644
--- a/src/genpy/dynamic.py
+++ b/src/genpy/dynamic.py
@@ -43,6 +43,7 @@ except ImportError:
import atexit
import os
+import re
import shutil
import sys
import tempfile
@@ -94,7 +95,7 @@ def _gen_dyn_modify_references(py_text, current_type, types):
# - remove any import statements
py_text = py_text.replace("import %s.msg"%pkg, '')
# - rewrite any references to class
- py_text = py_text.replace("%s.msg.%s"%(pkg, base_type), gen_name)
+ py_text = re.sub("(?<!\w)%s\.msg\.%s(?!\w)"%(pkg, base_type), gen_name, py_text)
pkg, base_type = genmsg.package_resource_name(current_type)
gen_name = _gen_dyn_name(pkg, base_type)
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/ros/genpy.git
More information about the debian-science-commits
mailing list