New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 740153 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Jul 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug

Blocking:
issue 738513



Sign in to add a comment

Running ui/gl/generate_bindings.py fails on collision between enum names

Project Member Reported by jmad...@chromium.org, Jul 7 2017

Issue description

Currently running the script produces this unhelpful error:

Traceback (most recent call last):
  File "generate_bindings.py", line 3403, in <module>
    sys.exit(main(sys.argv[1:]))
  File "generate_bindings.py", line 3384, in main
    GenerateEnumUtils(header_file, enum_header_filenames)
  File "generate_bindings.py", line 3020, in GenerateEnumUtils
    raise RunTimeError("code collision: %s and %s have the same code %s"
NameError: global name 'RunTimeError' is not defined

Fixing the naming of 'RunTimeError' -> 'RuntimeError' then gives:

Traceback (most recent call last):
  File "generate_bindings.py", line 3403, in <module>
    sys.exit(main(sys.argv[1:]))
  File "generate_bindings.py", line 3384, in main
    GenerateEnumUtils(header_file, enum_header_filenames)
  File "generate_bindings.py", line 3021, in GenerateEnumUtils
    %  (dict[value], name, value))
RuntimeError: code collision: GL_CLOSE_PATH_NV and GL_CLOSE_PATH_CHROMIUM have the same code 0x00

These enums are the same but defined in separate headers. Unsure of how to resolve this conflict, and haven't found where it started breaking.
 
Cc: kbr@chromium.org aleksand...@intel.com
Bisected this to https://codereview.chromium.org/2767063002

16-bit video upload to float: intermediate R16_EXT and copy to float.

The new third_party/khronos/GLES2/gl2ext.h includes the NV_path_rendering extension which causes the conflict.


Blocking: 738513
Project Member

Comment 3 by bugdroid1@chromium.org, Jul 7 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/43d64677dde45bbde789f77ecbba6687a54be850

commit 43d64677dde45bbde789f77ecbba6687a54be850
Author: Jamie Madill <jmadill@chromium.org>
Date: Fri Jul 07 21:02:48 2017

Fix ui/gl/generate_bindings.py.

This script had an incorrect exception (RunTimError -> RuntimeError)
and also was erroring on an enum-to-string function check. Fix the
naming of the exception error and allow for the same enum with a
different suffix to pick the first one arbitrarily, since they should
have the same value.

This also regenerates the generated files which were not up-to-date.

BUG= 740153 
R=piman@chromium.org

Change-Id: I2f6b982064bbedc8b7f4c12092ca1be5ea18e4df
Reviewed-on: https://chromium-review.googlesource.com/563503
Reviewed-by: Antoine Labour <piman@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
Cr-Commit-Position: refs/heads/master@{#485045}
[modify] https://crrev.com/43d64677dde45bbde789f77ecbba6687a54be850/ui/gl/generate_bindings.py
[modify] https://crrev.com/43d64677dde45bbde789f77ecbba6687a54be850/ui/gl/gl_bindings_autogen_egl.cc
[modify] https://crrev.com/43d64677dde45bbde789f77ecbba6687a54be850/ui/gl/gl_bindings_autogen_egl.h
[modify] https://crrev.com/43d64677dde45bbde789f77ecbba6687a54be850/ui/gl/gl_enums_implementation_autogen.h

Status: Fixed (was: Assigned)

Sign in to add a comment