davsclaus opened a new pull request, #29941: URL: https://github.com/apache/camel/pull/29941
Item 7 of [CAMEL-26931](https://issues.apache.org/jira/browse/CAMEL-26931): a missing input file, with exit codes and channels that differ. ## Problem - `camel dependency list|copy|sbom nosuch.yaml` printed "Path does not exist: nosuch.yaml" on stdout and exited 1 (`ProjectExporter.export`). The same code path is used by `camel export` and `camel kubernetes run`, which did the same. - `camel transform route nosuch.yaml` exited 1 without naming the file; with `--format=java` it exited 66, like `camel run`, `script`, `explain`, `harden` and `overview`. ## Change - `ProjectExporter`: the message goes to stderr and the exit code is 66 (`RunPipeline.FILE_NOT_FOUND`, which mirrors `CliExitCode.FILE_NOT_FOUND`). - `TransformRoute`: a file without a scheme that does not exist is "File does not exist: <file>" with exit 66 (as `camel run` words it), for every `--format`, before anything runs. The 4.24 upgrade guide adds these commands to the list of "a file that does not exist exits with `66` instead of `1`". ## Tests - `ProjectExporterTest.failsOnMissingFile`: exit 66, the message on stderr, nothing on stdout. - `TransformRouteTest.aFileThatDoesNotExistIsNotFound`: for `--format=java`, `xml` and `yaml`, exit 66 and the file in the message. - `KubernetesRunTest.shouldHandleMissingSourceFile`: exit 66, with "Path does not exist" on stderr. - camel-jbang-run: 303 pass. camel-jbang-core: 3004 + 259 (`DependencyUpdateTest` failed once and passed on the rerun, as on other branches). camel-jbang-plugin-kubernetes: 156 pass. _Claude Code on behalf of davsclaus_ 🤖 Generated with [Claude Code](https://claude.com/claude-code) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
