Ashfaq wrote:
> Hi Peter,
> The way you find the issue is really cool! Very cool! :)
Thanks ;)
Here's a bonus solution:
>>> import unittest
>>> class T(unittest.TestCase):
... def test_xy(self):
... self.maxDiff = None
... self.assertEqual(x, y)
...
>>> unittest.main()
F
==
On Jul 5, 2017 11:09 PM, "shubham goyal" wrote:
> Yha that's very smart. Only experience can drive you this way. Otherwise I
> was checking value by value.
>
> On Jul 5, 2017 10:21 PM, "Ashfaq" wrote:
>
> Hi Peter,
> The way you find the issue is really cool! Very cool! :)
>
> On Wed, Jul 5, 201
The difflib library (https://docs.python.org/2/library/difflib.html)
can also help with some exploratory discovery of the problem.
Here's an example:
>>> import difflib
>>> for line in difflib.context_diff(repr(x).split(','), repr(y).split(','
On 07/05/2017 11:09 AM, Marc Tompkins wrote:
> On Wed, Jul 5, 2017 at 9:51 AM, Ashfaq wrote:
>
>> Hi Peter,
>> The way you find the issue is really cool! Very cool! :)
>>
>>
> I agree - that is very cool. But I have also made this sort of mistake a
> few times, and found it by using a very quick
On Wed, Jul 5, 2017 at 9:51 AM, Ashfaq wrote:
> Hi Peter,
> The way you find the issue is really cool! Very cool! :)
>
>
I agree - that is very cool. But I have also made this sort of mistake a
few times, and found it by using a very quick, low-tech method...
"Unfold" the lines of the two dictio
Hi Peter,
The way you find the issue is really cool! Very cool! :)
On Wed, Jul 5, 2017 at 6:10 PM, shubham goyal wrote:
> Thank you Peter.
> Silly mistakes 😀
>
> On Jul 5, 2017 5:10 PM, "Peter Otten" <__pete...@web.de> wrote:
>
> > shubham goyal wrote:
> >
> > > null=None
> > > x={'_udp_options'
Thank you Peter.
Silly mistakes 😀
On Jul 5, 2017 5:10 PM, "Peter Otten" <__pete...@web.de> wrote:
> shubham goyal wrote:
>
> > null=None
> > x={'_udp_options': None, '_icmp_options': None, 'attribute_map':
> > {'icmp_options': 'icmpOptions', 'protocol': 'protocol', 'source':
> > {'source',
> > 't
shubham goyal wrote:
> null=None
> x={'_udp_options': None, '_icmp_options': None, 'attribute_map':
> {'icmp_options': 'icmpOptions', 'protocol': 'protocol', 'source':
> {'source',
> 'tcp_options': 'tcpOptions', 'is_stateless': 'isStateless', 'udp_options':
> 'udpOptions'}, '_is_stateless': False,
null=None
x={'_udp_options': None, '_icmp_options': None, 'attribute_map':
{'icmp_options': 'icmpOptions', 'protocol': 'protocol', 'source': 'source',
'tcp_options': 'tcpOptions', 'is_stateless': 'isStateless', 'udp_options':
'udpOptions'}, '_is_stateless': False, 'swagger_types': {'icmp_options':