Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update runner run function to be async. #27048

Merged
merged 1 commit into from
Jun 6, 2023
Merged

Conversation

krypton36
Copy link
Contributor

@krypton36 krypton36 commented Jun 2, 2023

Updating the runner.py run function to be async and moving the loop one level. This causes issues if the caller is already using an asynio loop, which test harness is doing.

This is the error I see in Test Harness:

Test Step Error: Error occurred during execution of test case TC-BINFO-1.1. this event loop is already running. Traceback (most recent call last): File "/app/./app/test_engine/models/test_case.py", line 207, in __execute_catch_errors await self.execute() File "/app/./app/chip_tool/test_case.py", line 317, in execute await super().execute() File "/app/./app/chip_tool/test_case.py", line 137, in execute await self.chip_tool.run_test(test_step_interface=self, test_id=test_name, test_type=self.test_type, test_parameters=self.test_parameters) File "/app/./app/chip_tool/chip_tool.py", line 519, in run_test return await self.run_websocket_test(test_step_interface, adapter, parser_builder_config) File "/app/./app/chip_tool/chip_tool.py", line 465, in run_websocket_test return await self.__test_harness_runner.run(parser_builder_config, runner_config) File "/usr/local/lib/python3.10/dist-packages/matter_yamltests/runner.py", line 147, in run result = loop.run_until_complete( File "uvloop/loop.pyx", line 1511, in uvloop.loop.Loop.run_until_complete File "uvloop/loop.pyx", line 1504, in uvloop.loop.Loop.run_until_complete File "uvloop/loop.pyx", line 1377, in uvloop.loop.Loop.run_forever File "uvloop/loop.pyx", line 518, in uvloop.loop.Loop._run RuntimeError: this event loop is already running.

@krypton36 krypton36 requested a review from vivien-apple June 2, 2023 18:07
@krypton36
Copy link
Contributor Author

@vivien-apple can you please take a look to make sure there are no issues with this?

@github-actions
Copy link

github-actions bot commented Jun 2, 2023

PR #27048: Size comparison from 7dcc847 to 43f9999

Increases (1 build for nrfconnect)
platform target config section 7dcc847 43f9999 change % change
nrfconnect all-clusters-app nrf7002dk_nrf5340_cpuapp text 790772 790776 4 0.0
Decreases (1 build for cc32xx)
platform target config section 7dcc847 43f9999 change % change
cc32xx lock CC3235SF_LAUNCHXL .debug_info 22707685 22707683 -2 -0.0
Full report (13 builds for cc32xx, efr32, linux, mbed, nrfconnect, qpg)
platform target config section 7dcc847 43f9999 change % change
cc32xx lock CC3235SF_LAUNCHXL (blank) 0 0 0 0.0
(read only) 605850 605850 0 0.0
(read/write) 204164 204164 0 0.0
.ARM.attributes 44 44 0 0.0
.ARM.exidx 8 8 0 0.0
.bss 197576 197576 0 0.0
.comment 206 206 0 0.0
.data 1468 1468 0 0.0
.debug_abbrev 951194 951194 0 0.0
.debug_aranges 117584 117584 0 0.0
.debug_frame 401012 401012 0 0.0
.debug_info 22707685 22707683 -2 -0.0
.debug_line 2853260 2853260 0 0.0
.debug_line_str 513 513 0 0.0
.debug_loc 33340 33340 0 0.0
.debug_loclists 1711471 1711471 0 0.0
.debug_ranges 4984 4984 0 0.0
.debug_rnglists 106453 106453 0 0.0
.debug_str 3758341 3758341 0 0.0
.ramVecs 780 780 0 0.0
.resetVecs 64 64 0 0.0
.rodata 104458 104458 0 0.0
.shstrtab 265 265 0 0.0
.stack 2048 2048 0 0.0
.strtab 484233 484233 0 0.0
.symtab 287408 287408 0 0.0
.text 499272 499272 0 0.0
efr32 lighting-app BRD4161A+rs9116 (read/write) 987924 987924 0 0.0
.bss 179856 179856 0 0.0
.data 2144 2144 0 0.0
.text 805904 805904 0 0.0
BRD4187C (read/write) 1019560 1019560 0 0.0
.bss 159588 159588 0 0.0
.data 2788 2788 0 0.0
.text 857164 857164 0 0.0
lock-app BRD4161A+wf200 (read/write) 1069240 1069240 0 0.0
.bss 174160 174160 0 0.0
.data 2152 2152 0 0.0
.text 892908 892908 0 0.0
window-app BRD4187C (read/write) 1090488 1090488 0 0.0
.bss 142572 142572 0 0.0
.data 2680 2680 0 0.0
.text 945216 945216 0 0.0
linux chip-tool-ipv6only arm64 (read only) 14808724 14808724 0 0.0
(read/write) 757608 757608 0 0.0
.bss 34408 34408 0 0.0
.data 3008 3008 0 0.0
.data.rel.ro 698304 698304 0 0.0
.dynamic 560 560 0 0.0
.got 16648 16648 0 0.0
.init 24 24 0 0.0
.init_array 224 224 0 0.0
.rodata 620200 620200 0 0.0
.text 12395956 12395956 0 0.0
thermostat-no-ble arm64 (read only) 2605196 2605196 0 0.0
(read/write) 142760 142760 0 0.0
.bss 52344 52344 0 0.0
.data 1736 1736 0 0.0
.data.rel.ro 79072 79072 0 0.0
.dynamic 560 560 0 0.0
.got 5512 5512 0 0.0
.init 24 24 0 0.0
.init_array 416 416 0 0.0
.rodata 129608 129608 0 0.0
.text 2210596 2210596 0 0.0
mbed lock-app CY8CPROTO_062_4343W+release (read only) 6224 6224 0 0.0
(read/write) 2496392 2496392 0 0.0
.bss 216304 216304 0 0.0
.data 5144 5144 0 0.0
.text 1459076 1459076 0 0.0
nrfconnect all-clusters-app nrf52840dk_nrf52840 (read only) 4 4 0 0.0
(read/write) 1190588 1190588 0 0.0
bss 154135 154135 0 0.0
rodata 135612 135612 0 0.0
text 820052 820052 0 0.0
nrf7002dk_nrf5340_cpuapp (read only) 4 4 0 0.0
(read/write) 1450424 1450424 0 0.0
bss 133875 133875 0 0.0
rodata 231672 231672 0 0.0
text 790772 790776 4 0.0
all-clusters-minimal-app nrf52840dk_nrf52840 (read only) 4 4 0 0.0
(read/write) 1131696 1131696 0 0.0
bss 152775 152775 0 0.0
rodata 109424 109424 0 0.0
text 788820 788820 0 0.0
qpg lighting-app qpg6105+debug (read/write) 1170468 1170468 0 0.0
.bss 99928 99928 0 0.0
.data 852 852 0 0.0
.text 617564 617564 0 0.0
lock-app qpg6105+debug (read/write) 1139852 1139852 0 0.0
.bss 94824 94824 0 0.0
.data 856 856 0 0.0
.text 586952 586952 0 0.0

@andy31415 andy31415 merged commit 77a92d4 into master Jun 6, 2023
@andy31415 andy31415 deleted the UpdateRunnerToBeAsync branch June 6, 2023 14:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants