Skip to content

concore validate reports errors but still exits successfully + doesn’t actually check file existence (docs mismatch) #303

@Titas-Ghosh

Description

@Titas-Ghosh

Hi @pradeeban ,
I noticed a gap between what concore validate claims to check and what it actually enforces.

The CLI README says validate checks file references and naming conventions. But in the current implementation, the validator collects errors and prints them, yet still exits with code 0, and it doesn’t actually verify whether the node source files exist (the inspect command does that, but validate doesn’t).

This makes concore validate hard to use in CI or pre‑commit checks, because workflows with real errors still look “successful” from the exit code.

What I expected

  • If validation errors are found, the CLI should exit non‑zero.
  • Optional: Validate node source file existence (defaulting to src/ like other commands).

What I’m seeing

Errors are printed, but the command completes successfully.
Missing node files aren’t flagged as errors (only inspect checks that).

People will rely on concore validate before running or in CI. If it always exits 0, it can silently let broken workflows through.

What i am thinking is that to

  • Return a structured result from validate_workflow (e.g., counts of errors/warnings).
  • In the CLI command, exit non‑zero when errors exist (sys.exit(1) or raise an exception).
  • Validate node file existence relative to the workflow’s directory and the source folder (default src/), and report missing files as errors.
  • Update tests to assert non‑zero exit code on validation errors, and add a test that fails when a referenced file is missing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions