Bug 225221 - [run-api-tests] Use webkitcorepy's TaskPool
Summary: [run-api-tests] Use webkitcorepy's TaskPool
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Jonathan Bedard
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-04-29 17:29 PDT by Jonathan Bedard
Modified: 2021-05-05 17:46 PDT (History)
4 users (show)

See Also:


Attachments
Patch (35.17 KB, patch)
2021-05-03 17:12 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff
Patch (43.23 KB, patch)
2021-05-04 15:37 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff
Patch (35.25 KB, patch)
2021-05-05 08:46 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff
Patch (37.29 KB, patch)
2021-05-05 10:53 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff
Patch (34.50 KB, patch)
2021-05-05 15:46 PDT, Jonathan Bedard
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch for landing (34.53 KB, patch)
2021-05-05 16:55 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Bedard 2021-04-29 17:29:30 PDT
In order for run-api-tests to support Python 3.8 on Apple's platforms, we need run-api-tests to use webkitcorepy's TaskPool.
Comment 1 Radar WebKit Bug Importer 2021-04-29 17:30:02 PDT
<rdar://problem/77352465>
Comment 2 Jonathan Bedard 2021-05-03 17:12:40 PDT
Created attachment 427625 [details]
Patch
Comment 3 Jonathan Bedard 2021-05-04 15:37:25 PDT
Created attachment 427703 [details]
Patch
Comment 4 Jonathan Bedard 2021-05-05 08:46:45 PDT
Created attachment 427768 [details]
Patch
Comment 5 Jonathan Bedard 2021-05-05 10:53:16 PDT
Created attachment 427780 [details]
Patch
Comment 6 dewei_zhu 2021-05-05 15:06:06 PDT
Comment on attachment 427780 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=427780&action=review

> Tools/Scripts/webkitpy/api_tests/runner.py:225
> +    if status == Runner.STATUS_PASSED and not output and Runner.instance.port.get_option('quiet'):
> +        Runner.instance.printer.write_update('{} {} {}'.format(worker, test, Runner.NAME_FOR_STATUS[status]))
> +    else:
> +        Runner.instance.printer.write_update('{} {} {}'.format(worker, test, Runner.NAME_FOR_STATUS[status]))

Are those expected to be identical?

> Tools/Scripts/webkitpy/api_tests/runner.py:233
> +class Runner(object):

Moving Runner to the bottom of this file make it more difficult to compare if we made any change to this class. Maybe move it back?
Comment 7 Jonathan Bedard 2021-05-05 15:46:50 PDT
Created attachment 427816 [details]
Patch
Comment 8 dewei_zhu 2021-05-05 16:39:42 PDT
Comment on attachment 427816 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=427816&action=review

r=me

> Tools/ChangeLog:18
> +        (_Worker.setup): Pass port object to worker process.
> +        (_Worker.setup): Pass port object to worker process.

Nit: those two lines are identical, we only need one, right?

> Tools/Scripts/webkitpy/api_tests/runner.py:118
> +            Runner.instance = self

Discussed in person, let's add an assertion that `Runner.instance is None` before this assignment.
Comment 9 Jonathan Bedard 2021-05-05 16:55:57 PDT
Created attachment 427822 [details]
Patch for landing
Comment 10 EWS 2021-05-05 17:22:22 PDT
Committed r277061 (237367@main): <https://commits.webkit.org/237367@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 427822 [details].