Title: [283329] trunk
- Revision
- 283329
- Author
- hironori.fu...@sony.com
- Date
- 2021-09-30 13:13:18 -0700 (Thu, 30 Sep 2021)
Log Message
Python 3 fails to run run-builtins-generator-tests : ModuleNotFoundError: No module named 'builtins_model'
https://bugs.webkit.org/show_bug.cgi?id=230870
Reviewed by Jonathan Bedard.
Source/_javascript_Core:
BaseException.message has been deprecated as of Python 2.6. Use
str(e) instead.
Implicit relative imports have been deprecated in Python 3.
Basically, relative imports should be used. However, the scripts
in wkbuiltins directory are flattened when they are copied to
WebKitBuild directory. So, relative imports can't be used.
So, append wkbuiltins directory to sys.path as a workaround.
* Scripts/generate-js-builtins.py:
Tools:
After r282424 (Bug 229879) switched to python3 for running
run-builtins-generator-tests on Buildbot, only WinCairo buildbot
was failing run-builtins-generator-tests.
run-builtins-generator-tests was invoking generate-js-builtins.py
explictly with 'python'. This is Python 2 on other bots.
Use sys.executable instead of 'python' to invoke
generate-js-builtins.py.
* Scripts/webkitpy/codegen/main.py:
(BuiltinsGeneratorTests.generate_from_js_builtins):
Modified Paths
Diff
Modified: trunk/Source/_javascript_Core/ChangeLog (283328 => 283329)
--- trunk/Source/_javascript_Core/ChangeLog 2021-09-30 20:05:55 UTC (rev 283328)
+++ trunk/Source/_javascript_Core/ChangeLog 2021-09-30 20:13:18 UTC (rev 283329)
@@ -1,3 +1,22 @@
+2021-09-30 Fujii Hironori <hironori.fu...@sony.com>
+
+ Python 3 fails to run run-builtins-generator-tests : ModuleNotFoundError: No module named 'builtins_model'
+ https://bugs.webkit.org/show_bug.cgi?id=230870
+
+ Reviewed by Jonathan Bedard.
+
+ BaseException.message has been deprecated as of Python 2.6. Use
+ str(e) instead.
+
+ Implicit relative imports have been deprecated in Python 3.
+ Basically, relative imports should be used. However, the scripts
+ in wkbuiltins directory are flattened when they are copied to
+ WebKitBuild directory. So, relative imports can't be used.
+
+ So, append wkbuiltins directory to sys.path as a workaround.
+
+ * Scripts/generate-js-builtins.py:
+
2021-09-29 Mark Lam <mark....@apple.com>
DFG strength reduction on % operator should handle an INT_MIN divisor.
Modified: trunk/Source/_javascript_Core/Scripts/generate-js-builtins.py (283328 => 283329)
--- trunk/Source/_javascript_Core/Scripts/generate-js-builtins.py 2021-09-30 20:05:55 UTC (rev 283328)
+++ trunk/Source/_javascript_Core/Scripts/generate-js-builtins.py 2021-09-30 20:13:18 UTC (rev 283329)
@@ -33,6 +33,8 @@
import os
import sys
+sys.path.append(os.path.join(os.path.dirname(__file__), 'wkbuiltins'))
+
logging.basicConfig(format='%(levelname)s: %(message)s', level=logging.ERROR)
log = logging.getLogger('global')
@@ -178,6 +180,6 @@
generate_bindings_for_builtins_files(builtins_files=input_filepaths, **options)
except ParseException as e:
if arg_options.test:
- log.error(e.message)
+ log.error(str(e))
else:
raise # Force the build to fail.
Modified: trunk/Tools/ChangeLog (283328 => 283329)
--- trunk/Tools/ChangeLog 2021-09-30 20:05:55 UTC (rev 283328)
+++ trunk/Tools/ChangeLog 2021-09-30 20:13:18 UTC (rev 283329)
@@ -1,3 +1,23 @@
+2021-09-30 Fujii Hironori <hironori.fu...@sony.com>
+
+ Python 3 fails to run run-builtins-generator-tests : ModuleNotFoundError: No module named 'builtins_model'
+ https://bugs.webkit.org/show_bug.cgi?id=230870
+
+ Reviewed by Jonathan Bedard.
+
+ After r282424 (Bug 229879) switched to python3 for running
+ run-builtins-generator-tests on Buildbot, only WinCairo buildbot
+ was failing run-builtins-generator-tests.
+
+ run-builtins-generator-tests was invoking generate-js-builtins.py
+ explictly with 'python'. This is Python 2 on other bots.
+
+ Use sys.executable instead of 'python' to invoke
+ generate-js-builtins.py.
+
+ * Scripts/webkitpy/codegen/main.py:
+ (BuiltinsGeneratorTests.generate_from_js_builtins):
+
2021-09-30 John Wilander <wilan...@apple.com>
PCM: Take app bundle ID into consideration when matching triggering events with pending clicks
Modified: trunk/Tools/Scripts/webkitpy/codegen/main.py (283328 => 283329)
--- trunk/Tools/Scripts/webkitpy/codegen/main.py 2021-09-30 20:05:55 UTC (rev 283328)
+++ trunk/Tools/Scripts/webkitpy/codegen/main.py 2021-09-30 20:13:18 UTC (rev 283329)
@@ -26,6 +26,7 @@
import os
import os.path
import shutil
+import sys
import tempfile
from webkitpy.common.checkout.scm.detection import detect_scm_system
from webkitpy.common.system.executive import ScriptError
@@ -38,7 +39,7 @@
self.executive = executive
def generate_from_js_builtins(self, builtins_files, output_directory, framework_name="", combined_outputs=False, generate_wrappers=False):
- cmd = ['python',
+ cmd = [sys.executable,
'_javascript_Core/Scripts/generate-js-builtins.py',
'--output-directory', output_directory,
'--force',
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes