Skip to content

Commit 76e650e

Browse files
LaurentiuM1234kv2019i
authored andcommitted
.github/zephyr: switch to python 3.10 on windows
Zephyr commit b3b8360f3993 ("west: runners: Add `west rtt` command with pyocd implementation") adds some functionality to the west commands making use of the pipe ("|") operator for function return type hinting. As per PEP 604 [1], this operator can be used for writing union types starting from python 3.10. Since the SOF windows builds use python 3.8 this leads to the CI failing. To fix this, switch to using python 3.10. This is not a problem for Linux CI jobs as they already use python 3.10. The following is a snippet of a failed windows CI job regarding this: File "D:\a\sof\sof\workspace\zephyr\scripts/west_commands\runners\core.py", line 780, in ZephyrBinaryRunner def get_rtt_address(self) -> int | None: TypeError: unsupported operand type(s) for |: 'type' and 'NoneType' [1]: https://peps.python.org/pep-0604/ Signed-off-by: Laurentiu Mihalcea <laurentiu.mihalcea@nxp.com>
1 parent 89e417a commit 76e650e

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

.github/workflows/zephyr.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -305,7 +305,7 @@ jobs:
305305
- name: Setup Python
306306
uses: actions/setup-python@v5
307307
with:
308-
python-version: '3.8'
308+
python-version: '3.10'
309309

310310
- name: West install
311311
run: pip3 install west
@@ -329,7 +329,7 @@ jobs:
329329
uses: actions/setup-python@v5
330330
id: cache-python
331331
with:
332-
python-version: '3.8'
332+
python-version: '3.10'
333333
cache: 'pip'
334334
cache-dependency-path: workspace/zephyr/scripts/requirements.txt
335335

0 commit comments

Comments
 (0)