Skip to content

Commit e395a9a

Browse files
kartbendkalowsk
authored andcommitted
doc: _scripts: ensure twister.yaml file is considered in board catalog
Boards may use twister.yaml file to define Twister platforms, so board catalog should also parse them. Fixes: #95721. Signed-off-by: Benjamin Cabé <[email protected]> (cherry picked from commit 9f181b6)
1 parent 9526404 commit e395a9a

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

doc/_scripts/gen_boards_catalog.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -360,14 +360,14 @@ def get_catalog(generate_hw_features=False, hw_features_vendor_filter=None):
360360
# Grab all the twister files for this board and use them to figure out all the archs it
361361
# supports.
362362
board_archs = set()
363-
pattern = f"{board.name}*.yaml"
364-
for twister_file in board.dir.glob(pattern):
365-
try:
366-
with open(twister_file) as f:
367-
board_data = yaml.safe_load(f)
368-
board_archs.add(board_data.get("arch"))
369-
except Exception as e:
370-
logger.error(f"Error parsing twister file {twister_file}: {e}")
363+
for pattern in (f"{board.name}*.yaml", "twister.yaml"):
364+
for twister_file in board.dir.glob(pattern):
365+
try:
366+
with open(twister_file) as f:
367+
board_data = yaml.safe_load(f)
368+
board_archs.add(board_data.get("arch"))
369+
except Exception as e:
370+
logger.error(f"Error parsing twister file {twister_file}: {e}")
371371

372372
if doc_page and doc_page.is_relative_to(ZEPHYR_BASE):
373373
doc_page_path = doc_page.relative_to(ZEPHYR_BASE).as_posix()

0 commit comments

Comments
 (0)