diff options
| author | Jamie Madill <jmadill@chromium.org> | 2017-11-08 13:40:09 -0500 |
|---|---|---|
| committer | Tobin Ehlis <tobine@google.com> | 2017-11-09 08:43:30 -0700 |
| commit | 931a3936ecf30348013e0e3dd14cce02eb0c0beb (patch) | |
| tree | 5abc35927f754ebac3a0189adce0bdfeea25aa67 /scripts/object_tracker_generator.py | |
| parent | 81b72c5154430076dfc889f55f58ca2402497ea1 (diff) | |
| download | usermoji-931a3936ecf30348013e0e3dd14cce02eb0c0beb.tar.xz | |
layers: Make generator helpers Python 2 compatible.
This is an easy compatiblity change, which uses a workaround to import
a version of 'open' that can support unicode across Python versions.
Affects the object tracker and parameter validation generators.
Change-Id: Ie958dc64168db9e06b36321b4b6ad2336f995ea3
Diffstat (limited to 'scripts/object_tracker_generator.py')
| -rw-r--r-- | scripts/object_tracker_generator.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/scripts/object_tracker_generator.py b/scripts/object_tracker_generator.py index 33c8b3e7..50e19cc3 100644 --- a/scripts/object_tracker_generator.py +++ b/scripts/object_tracker_generator.py @@ -25,6 +25,9 @@ from generator import * from collections import namedtuple from vuid_mapping import * +# This is a workaround to use a Python 2.7 and 3.x compatible syntax. +from io import open + # ObjectTrackerGeneratorOptions - subclass of GeneratorOptions. # # Adds options used by ObjectTrackerOutputGenerator objects during |
