From: Salvatore Orlando Date: Wed, 10 Jul 2013 16:11:01 +0000 (+0200) Subject: Re-assign quantum.api module as last operation X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=c2d8b0b27c92a819074d6bc619510c563150c01e;p=openstack-build%2Fneutron-build.git Re-assign quantum.api module as last operation Bug 1199443 This avoids reset of locals in quantum/api/__init__.py, resulting in sys being None when assigning quantum.api.extensions to neutron.api.extensions Change-Id: I2da8b336679b643c92824399a05ca1b9980d1598 --- diff --git a/quantum/api/__init__.py b/quantum/api/__init__.py index e30a54c03..4f87171a1 100644 --- a/quantum/api/__init__.py +++ b/quantum/api/__init__.py @@ -29,6 +29,8 @@ warnings.warn( _('You are using old configuration values for the api-paste config. ' 'Please update for Neutron.') ) -sys.modules['quantum.api'] = api sys.modules['quantum.api.extensions'] = extensions sys.modules['quantum.api.v2'] = v2 +# The following assigment must be performed at the end of the module. +# Otherwise local variables will be overwritten. +sys.modules['quantum.api'] = api