Fixes bug 1286187
Neither execute_get_output() nor execute() would wait for the process to
fully finish executing. This could potentially create a race condition
where commands execute in a different order than intended.
Also, for execute() it could cause a process to never finish executing if
it generates enough output to block writing to the pipe.
Change-Id: I3404f4b3ca1cddeec2f3e7b393817a6ccc42bec7
We don't need to have the vi modelines in each source file,
it can be set in a user's vimrc if required.
Also a check is added to hacking to detect if they are re-added.
Change-Id: I347307a5145b2760c69085b6ca850d6a9137ffc6
Closes-Bug: #1229324
Due to some issues in the gate, several flake8 errors got merged
recently. This patch fixes the most recent issues found.
For the H304 relative import errors, we have to skip those because they
are put into /etc/xensource/scripts which is the current working
directory when running the plugin.
For the H231 incompatible python 3 'except x,y' construct, we have to
skip those because this code is written to run on python 2.4 and 'except
x as y' does not work with python 2.4.
Note that in cleaning up some of the H304 failures for relative imports,
I also re-arranged the imports to follow the hacking guide of doing
standard library packages first, then third party packages, and finally
nova-specific packages.
Closes-Bug: #1229753
Change-Id: I1c2211fd6a10d43d7e65cdb4e18530397788cf2c
fix the N402 errors that have slipped in in the last 48 hrs since
starting this patch series.
fix an N401 error that our scanner current can't find because it
only looks for doc strings on classes and defs.
this is the xeno's paradox of patch series, but we're getting close.
Change-Id: I4a763bb4c812335d853eae05c72464f18ab93297
Looks like this fixes all HACKING problems that were around.
Thanks to Dina Belova and Alexander Kovalev for this work.
Change-Id: I8157f0d4890184c1216aab63ef7180ee8b7a184d
If domain 0 has an IP address on a given bridge, then add a flow rule to
allow traffic to leave that port. This allows for the case where domain 0
and the tenant network are sharing a bridge, which is useful in non-production
environments.
At the same time, simplify the interface to ovs_configure_base_rules.py.
There is no need to pass the bridge in, because it's implicit in the selection
of the physical interface, and can be obtained using ovs-vsctl iface-to-br.
Having made these two changes, it's now reasonable to apply flow rules to all
interfaces as a default (if not overridden in the sysconfig file).
Change-Id: I2a33ed55246d49b0e4f57db909e1b40351d27602