On 01/12/2016 03:02 PM, Chris Dent wrote: > On Tue, 12 Jan 2016, Amrith Kumar wrote: > >> if var > 0: >> ... something ... >> >> To >> >> if var: >> ... something ... > > I may be missing something but the above is not a stylistic change > if var can ever be negative. In one of the ceilometer changes[1] for > example, this change will change the flow of the code. In this > particular example if some caller do _do_test_iter_images sends > page_size=-1 bad things will happen. Since it is test code the scope > of the damage is limited, but I prefer the more explicit > 0. > > I've not checked all the reviews but if it is showing up in one > place seems like it could in others. > > [1] > https://review.openstack.org/#/c/266211/1/ceilometer/tests/unit/image/test_glance.py >
Same thing for Cinder change - it's failing multiple unit tests because this changes the logic of the statement. __________________________________________________________________________ OpenStack Development Mailing List (not for usage questions) Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev