Repository navigation
fix(mkconcore): allow node labels with no source file - #685
yadavchiragg wants to merge 4 commits into
Conversation
Maintainer confirmed port-only nodes (IN:/OUT:) are meant to be supported. validate no longer reports 'has no filename' for them; mkconcore already builds them. The test now asserts port-only nodes validate.
|
@yadavchiragg looks like some tests are failing. Pls check https://github.com/ControlCore-Project/concore/actions/runs/43670687823/job/137421714976?pr=685 |
|
Thanks @pradeeban. None of these failures come from this PR. It changes no C++ files, and the Python tests pass locally with results identical to dev.
I'll rebase #685 once those are merged so CI can re-run. |
|
@yadavchiragg but there are some merge conflicts now. Pls check. |
|
@pradeeban I merged the latest dev and resolved the conflict in validate.py (dev added ".jl" to the same extension list, so I kept both changes). The remaining red checks are not from this PR: test (3.9) and the cancelled 3.10-3.12 jobs are the Ubuntu 26.04 / Python 3.9 problem that #678 fixes, and the cpp-* jobs are the params path in the C++ test that #714 fixes. Once those two are merged I'll re-run CI here. |
|
@yadavchiragg looks like some more merge conflicts. |
|
@pradeeban I merged the latest dev again and resolved the new conflict in validate.py (dev added the --type pulled-container check, so the port-only guard now wraps it). dev also now fails a build when a node's source file is missing, which several bundled workflows hit, so test_port_only_nodes.py now creates an empty file for each node before building. All 16 checks were green on the previous push. |
Fixes #684
Problem:
mkconcore.pyraisesValueError: Node source file '' cannot be emptyfor any node whose label has an empty source part, such asIN:orOUT:. 22 of the.graphmlfiles in the repository have such port-only nodes (0mq/,measurements/,ratc/yuyu*learn*.graphml,testsou/), and none of them can be built. The rest ofmkconcore.pystill handles a node without a source file (it checkslen(sourcecode) != 0/if not sourcecodein several places), so the label validation is stricter than the generator.Change: only validate the source part with
safe_relpathwhen it is non-empty. Non-empty sources are validated exactly as before, so unsafe source paths are still rejected.Testing: new
tests/test_port_only_nodes.pyfinds every workflow in the repo that contains a port-only node and builds it for posix, windows and docker. On currentdevall 66 build cases fail; with this change all pass.ruff format --checkandruff checkare clean.