Commit 238196dc authored by Kevin Modzelewski's avatar Kevin Modzelewski

babel wanted to set __builtins__

I'm not quite sure what they're trying to use it for, but it looks
like it doesn't really do anything.  And we're no worse off with the
patch+assert than simply ignoring the behavior.
parent 7c93e74e
diff --git a/babel/messages/extract.py b/babel/messages/extract.py
index 2f8084a..22fc289 100644
--- a/babel/messages/extract.py
+++ b/babel/messages/extract.py
@@ -421,7 +421,7 @@ def extract_python(fileobj, keywords, comment_tags, options):
# https://sourceforge.net/tracker/?func=detail&atid=355470&
# aid=617979&group_id=5470
value = eval('# coding=%s\n%s' % (str(encoding), value),
- {'__builtins__':{}}, {})
+ {}, {})
if PY2 and not isinstance(value, text_type):
value = value.decode(encoding)
buf.append(value)
...@@ -12,6 +12,9 @@ NOSETESTS_EXE = os.path.abspath(os.path.join(ENV_NAME, "bin", "nosetests")) ...@@ -12,6 +12,9 @@ NOSETESTS_EXE = os.path.abspath(os.path.join(ENV_NAME, "bin", "nosetests"))
packages = ["nose==1.3.7", "pytz==2015.4", "-e", "git+http://github.com/mitsuhiko/babel.git@1.3#egg=Babel"] packages = ["nose==1.3.7", "pytz==2015.4", "-e", "git+http://github.com/mitsuhiko/babel.git@1.3#egg=Babel"]
create_virtenv(ENV_NAME, packages, force_create = True) create_virtenv(ENV_NAME, packages, force_create = True)
PATCH_FILE = os.path.abspath(os.path.join(os.path.dirname(__file__), "babel.patch"))
subprocess.check_call(["patch", "-p1", "--input=" + PATCH_FILE], cwd=BABEL_DIR)
subprocess.check_call([PYTHON_EXE, "setup.py", "import_cldr"], cwd=BABEL_DIR) subprocess.check_call([PYTHON_EXE, "setup.py", "import_cldr"], cwd=BABEL_DIR)
subprocess.check_call([PYTHON_EXE, "setup.py", "build"], cwd=BABEL_DIR) subprocess.check_call([PYTHON_EXE, "setup.py", "build"], cwd=BABEL_DIR)
subprocess.check_call([PYTHON_EXE, "setup.py", "install"], cwd=BABEL_DIR) subprocess.check_call([PYTHON_EXE, "setup.py", "install"], cwd=BABEL_DIR)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment