Skip to content

Commit

Permalink
Don't depend on execfile in virtualenv.py
Browse files Browse the repository at this point in the history
This is gone in Python 3 and prevents otherwise Py3-compatible wpt
commands working with `python3 wpt`.
  • Loading branch information
jgraham authored and gsnedders committed Oct 10, 2019
1 parent f68f786 commit ccbf1f9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tools/wpt/virtualenv.py
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,8 @@ def working_set(self):

def activate(self):
path = os.path.join(self.bin_path, "activate_this.py")
execfile(path, {"__file__": path}) # noqa: F821
with open(path) as f:
exec(f.read(), {"__file__": path})

def start(self):
if not self.exists or self.broken_link:
Expand Down

0 comments on commit ccbf1f9

Please sign in to comment.