lava-nc / lava

A Software Framework for Neuromorphic Computing
https://lava-nc.org
Other
555 stars 143 forks source link

Fix partition parse bug for internal vLab #741

Closed tim-shea closed 1 year ago

tim-shea commented 1 year ago

Issue Number: #739

Objective of pull request: Fixing a bug from earlier merge due to invalid partition rows in sinfo.

Pull request checklist

Your PR fulfills the following requirements:

Pull request type

What is the current behavior?

What is the new behavior?

Does this introduce a breaking change?

harryliu-intel commented 1 year ago

Not specifically about the new change... But a partition could appear more than once in sinfo if some nodes are up, some are done, e.g.:

og_gdc             up      30:00      1  down* ncl-gdc-og-07 og_gdc             up      30:00      3   idle ncl-gdc-og-[02,04,08]

It seems like both will be parsed by get_partitions, but get_partition_info returns only the first one. So if not all boards are down in a partition, the code might complain the partition is down when it's still possible to run.