<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>262369</bug_id>
          
          <creation_ts>2023-09-29 07:48:42 -0700</creation_ts>
          <short_desc>[webkitpy] Update twisted and pyopenssl autoinstalled versions (fix issues with python-3.11 and WPE ARM32 perf bots)</short_desc>
          <delta_ts>2023-10-17 19:51:14 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Tools / Tests</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=262512</see_also>
    
    <see_also>https://bugs.webkit.org/show_bug.cgi?id=263299</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Carlos Alberto Lopez Perez">clopez</reporter>
          <assigned_to name="Carlos Alberto Lopez Perez">clopez</assigned_to>
          <cc>gsnedders</cc>
    
    <cc>jbedard</cc>
    
    <cc>philn</cc>
    
    <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1981270</commentid>
    <comment_count>0</comment_count>
    <who name="Carlos Alberto Lopez Perez">clopez</who>
    <bug_when>2023-09-29 07:48:42 -0700</bug_when>
    <thetext>The WPE Perf bots for ARM-32 are having issues with the WebKit python autoinstall modules.

See: https://build.webkit.org/#/builders/892/builds/1912


The are two issues there:

1)

The current versions of twisted auto-installed from Tools/Scripts/webkitpy/autoinstalled/twisted.py fail to build on a system with python-3.11

See:

creating build/temp.linux-armv7l-3.11
creating build/temp.linux-armv7l-3.11/src
creating build/temp.linux-armv7l-3.11/src/twisted
creating build/temp.linux-armv7l-3.11/src/twisted/test
arm-poky-linux-gnueabi-gcc -mthumb -mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7 -fstack-protector-strong -O2 -D_FORTIFY_SOURCE=2 -Wformat -Wformat-security -Werror=format-security -Wsign-compare -DNDEBUG -g -O3 -Wall -O2 -pipe -g -feliminate-unused-debug-types -fmacro-prefix-map=/python3/3.11.2-r0/Python-3.11.2=/usr/src/debug/python3/3.11.2-r0 -fdebug-prefix-map=/python3/3.11.2-r0/Python-3.11.2=/usr/src/debug/python3/3.11.2-r0 -fmacro-prefix-map=/build/path/unavailable/=/usr/src/debug/python3/3.11.2-r0 -fdebug-prefix-map=/build/path/unavailable/=/usr/src/debug/python3/3.11.2-r0 -fdebug-prefix-map== -fmacro-prefix-map== -fdebug-prefix-map== -O2 -pipe -g -feliminate-unused-debug-types -fmacro-prefix-map=/python3/3.11.2-r0/Python-3.11.2=/usr/src/debug/python3/3.11.2-r0 -fdebug-prefix-map=/python3/3.11.2-r0/Python-3.11.2=/usr/src/debug/python3/3.11.2-r0 -fmacro-prefix-map=/build/path/unavailable/=/usr/src/debug/python3/3.11.2-r0 -fdebug-prefix-map=/build/path/unavailable/=/usr/src/debug/python3/3.11.2-r0 -fdebug-prefix-map== -fmacro-prefix-map== -fdebug-prefix-map== -fPIC -I/usr/include/python3.11 -c src/twisted/test/raiser.c -o build/temp.linux-armv7l-3.11/src/twisted/test/raiser.o
src/twisted/test/raiser.c:198:12: fatal error: longintrepr.h: No such file or directory
  198 |   #include &quot;longintrepr.h&quot;
      |            ^~~~~~~~~~~~~~~


This is related to  https://github.com/python/cpython/pull/28968 and https://github.com/cython/cython/pull/4428 (also related: https://github.com/aio-libs/aiohttp/issues/6600 )
And has been fixed in newer releases of twisted.



2) pyopenssl gives a failure when starting the benchmark

$ Tools/Scripts/run-benchmark --count 1 --plan sunspider
2023-09-29 14:26:06,949 - INFO - Ensure dependencies of http server is satisfied
Traceback (most recent call last):
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/run-benchmark&quot;, line 13, in &lt;module&gt;
    sys.exit(main())
             ^^^^^^
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/webkitpy/benchmark_runner/run_benchmark.py&quot;, line 177, in main
    return start(parse_args(config_argument_parser()))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/webkitpy/benchmark_runner/run_benchmark.py&quot;, line 165, in start
    run_benchmark_plan(args, args.plan)
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/webkitpy/benchmark_runner/run_benchmark.py&quot;, line 99, in run_benchmark_plan
    runner = benchmark_runner_class(plan,
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/webkitpy/benchmark_runner/webserver_benchmark_runner.py&quot;, line 27, in __init__
    self._http_server_driver = HTTPServerDriverFactory.create(platform)
                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/webkitpy/benchmark_runner/generic_factory.py&quot;, line 13, in create
    return cls.products[description]()
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/webkitpy/benchmark_runner/http_server_driver/simple_http_server_driver.py&quot;, line 27, in __init__
    self._ensure_http_server_dependencies()
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/webkitpy/benchmark_runner/http_server_driver/simple_http_server_driver.py&quot;, line 118, in _ensure_http_server_dependencies
    from webkitpy.autoinstalled import twisted
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/webkitpy/autoinstalled/twisted.py&quot;, line 42, in &lt;module&gt;
    from twisted.protocols.tls import TLSMemoryBIOFactory
  File &quot;/usr/lib/python3.11/site-packages/twisted/protocols/tls.py&quot;, line 42, in &lt;module&gt;
    from OpenSSL.SSL import Connection, Error, SysCallError, WantReadError, ZeroReturnError
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/libraries/autoinstalled/python-3-armv7l/OpenSSL/__init__.py&quot;, line 8, in &lt;module&gt;
    from OpenSSL import crypto, SSL
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/libraries/autoinstalled/python-3-armv7l/OpenSSL/crypto.py&quot;, line 1556, in &lt;module&gt;
    class X509StoreFlags(object):
  File &quot;/opt/worker/WPE-Linux-RPi4-32bits-Mesa-Release-Perf-Tests/build/Tools/Scripts/libraries/autoinstalled/python-3-armv7l/OpenSSL/crypto.py&quot;, line 1577, in X509StoreFlags
    CB_ISSUER_CHECK = _lib.X509_V_FLAG_CB_ISSUER_CHECK
                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: module &apos;lib&apos; has no attribute &apos;X509_V_FLAG_CB_ISSUER_CHECK&apos;


This is also fixed by upgrading pyopenssl</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1981275</commentid>
    <comment_count>1</comment_count>
    <who name="Carlos Alberto Lopez Perez">clopez</who>
    <bug_when>2023-09-29 07:55:15 -0700</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/18412</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1981729</commentid>
    <comment_count>2</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2023-10-02 06:04:17 -0700</bug_when>
    <thetext>Committed 268723@main (4ae17ef2311b): &lt;https://commits.webkit.org/268723@main&gt;

Reviewed commits have been landed. Closing PR #18412 and removing active labels.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1981730</commentid>
    <comment_count>3</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2023-10-02 06:05:14 -0700</bug_when>
    <thetext>&lt;rdar://problem/116342308&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1981867</commentid>
    <comment_count>4</comment_count>
    <who name="Jonathan Bedard">jbedard</who>
    <bug_when>2023-10-02 14:50:13 -0700</bug_when>
    <thetext>We&apos;re going to have to conditionalize 268723@main on Python 3.11. The previous specified versions of Twisted and OpenSSL were picked because they match what ews-build.webkit.org and build.webkit.org are running.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1981873</commentid>
    <comment_count>5</comment_count>
    <who name="Sam Sneddon [:gsnedders]">gsnedders</who>
    <bug_when>2023-10-02 15:02:41 -0700</bug_when>
    <thetext>I don&apos;t understand how the patch fixed things?

The AutoInstaller _cannot_ install Twisted 23.8.0, because we don&apos;t support PEP 517 builders (Bug 261082). I think 22.10.0 is the latest version on PyPI the AutoInstaller should be able to install?

The commit message is also wrong to say &quot;there aren&apos;t much pre-built pip packages for ARM32&quot;, because unless wheel=True is passed we _don&apos;t use pre-built packages_.

This has, resultantly, broken certain internal CI jobs with a traceback ending in:

  File &quot;/Volumes/Data/worker/ews-tools-trybot/build/OpenSource/Tools/Scripts/webkitpy/autoinstalled/buildbot.py&quot;, line 27, in &lt;module&gt;
    from webkitpy.autoinstalled import twisted
  File &quot;/Volumes/Data/worker/ews-tools-trybot/build/OpenSource/Tools/Scripts/webkitpy/autoinstalled/twisted.py&quot;, line 43, in &lt;module&gt;
    from twisted.protocols.tls import TLSMemoryBIOFactory
ModuleNotFoundError: No module named &apos;twisted&apos;

In general, we would rather the versions match those we use on our buildbot instances, but clearly that doesn&apos;t work for all configurations.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>