cinder/tools/flakes.py
Joe Gordon eeb6f8c77f import tools/flakes from oslo
Change-Id: Iac52a0cc48de9f29a91545e319c144e3f935799d
2013-01-31 10:40:03 -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())