Thank you for fixing. Looks good. On 2016年02月17日 00:37, Corey Bryant wrote: > Signed-off-by: Corey Bryant <[email protected]> > --- > ryu/ofproto/ofproto_parser.py | 2 +- > ryu/ofproto/oxx_fields.py | 2 +- > ryu/tests/unit/packet/test_packet.py | 4 ++-- > 3 files changed, 4 insertions(+), 4 deletions(-) > > diff --git a/ryu/ofproto/ofproto_parser.py b/ryu/ofproto/ofproto_parser.py > index 1e553ca..670878d 100644 > --- a/ryu/ofproto/ofproto_parser.py > +++ b/ryu/ofproto/ofproto_parser.py > @@ -170,7 +170,7 @@ class MsgBase(StringifyMixin): > > def __str__(self): > def hexify(x): > - return hex(x) if isinstance(x, int) else x > + return hex(x) if isinstance(x, six.integer_types) else x > buf = 'version=%s,msg_type=%s,msg_len=%s,xid=%s,' %\ > (hexify(self.version), hexify(self.msg_type), > hexify(self.msg_len), hexify(self.xid)) > diff --git a/ryu/ofproto/oxx_fields.py b/ryu/ofproto/oxx_fields.py > index e1e47aa..e9c1fb9 100644 > --- a/ryu/ofproto/oxx_fields.py > +++ b/ryu/ofproto/oxx_fields.py > @@ -82,7 +82,7 @@ def _get_field_info_by_number(oxx, num_to_field, n): > name = f.name > except KeyError: > t = type_desc.UnknownType > - if isinstance(n, int): > + if isinstance(n, six.integer_types): > name = 'field_%d' % (n,) > else: > raise KeyError('unknown %s field number: %s' % (oxx.upper(), n)) > diff --git a/ryu/tests/unit/packet/test_packet.py > b/ryu/tests/unit/packet/test_packet.py > index a793a5f..c48e372 100644 > --- a/ryu/tests/unit/packet/test_packet.py > +++ b/ryu/tests/unit/packet/test_packet.py > @@ -697,7 +697,7 @@ class TestPacket(unittest.TestCase): > sctp_values = {'src_port': 1, > 'dst_port': 1, > 'vtag': 0, > - 'csum': p_sctp.csum, > + 'csum': repr(p_sctp.csum), > 'chunks': data_str} > _sctp_str = ','.join(['%s=%s' % (k, sctp_values[k]) > for k, _ in inspect.getmembers(p_sctp) > @@ -1233,7 +1233,7 @@ class TestPacket(unittest.TestCase): > sctp_values = {'src_port': 1, > 'dst_port': 1, > 'vtag': 0, > - 'csum': p_sctp.csum, > + 'csum': repr(p_sctp.csum), > 'chunks': data_str} > _sctp_str = ','.join(['%s=%s' % (k, sctp_values[k]) > for k, _ in inspect.getmembers(p_sctp) >
------------------------------------------------------------------------------ Site24x7 APM Insight: Get Deep Visibility into Application Performance APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month Monitor end-to-end web transactions and take corrective actions now Troubleshoot faster and improve end-user experience. Signup Now! http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140 _______________________________________________ Ryu-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/ryu-devel
