nova/tools/flakes.py
Joe Gordon 64ded79907 import tools/flakes from oslo
Change-Id: Id6d99fe1fd39e8c061f591e9a82058aea9664674
2013-01-31 12:29:14 -08:00

16 lines
377 B
Python

"""
wrapper for pyflakes to ignore gettext based warning:
"undefined name '_'"
Synced in from openstack-common
"""
import sys
import pyflakes.checker
from pyflakes.scripts import pyflakes
if __name__ == "__main__":
orig_builtins = set(pyflakes.checker._MAGIC_GLOBALS)
pyflakes.checker._MAGIC_GLOBALS = orig_builtins | set(['_'])
sys.exit(pyflakes.main())