]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Remove use of contextlib.nested
authorankitagrawal <ankit11.agrawal@nttdata.com>
Thu, 14 May 2015 11:08:36 +0000 (04:08 -0700)
committerankitagrawal <ankit11.agrawal@nttdata.com>
Thu, 21 May 2015 21:48:28 +0000 (14:48 -0700)
commit032847b3030106a9e605b3088826b599789d7991
tree6511c600380f35afb10a8c24608d74e19fcf47ae
parent55c3cdecb39169e6c7d5fcb98fa7b3aa803b4f6e
Remove use of contextlib.nested

Removed use of contextlib.nested call from codebase, as it has been
deprecated since Python 2.7.

There are also known issues with contextlib.nested that were addressed
by the native support for multiple "with" variables. For instance, if
the first object is created but the second one throws an exception,
the first object's __exit__ is never called. For more information see
https://docs.python.org/2/library/contextlib.html#contextlib.nested
contextlib.nested is also not compatible with Python 3.

Multi-patch set for easier chunks. This one addresses the
neutron/plugins/ml2 directory.

Line continuation markers (e.g. '\') had to be used or syntax
errors were thrown. While using parentheses is the preferred way
for multiple line statements, but in case of long with statements
backslashes are acceptable.

Partial-Bug: 1428424
Change-Id: I7bbe4cec511125b4b2c954aa93e2d9ff6871b9e0
neutron/hacking/checks.py
neutron/plugins/ml2/plugin.py