Cloud file-reading flags report bare 'No such file or directory' without the flag or path
Maintainers usually reply within 1 day
Assessment
This issue has not been assessed yet.
Description
What happens
A missing or unreadable file passed to several Cloud flags fails with {"error":{"code":"io","message":"No such file or directory (os error 2)"}}, naming neither the flag nor the path. cloud udf create/update --artifact says only 'Cannot open UDF ZIP archive' and drops the OS error as well.
Evidence
0.5.0 @ 6859d2ac: chctl cloud service query <id> --queries-file nope.sql gives exit 1 and the message above. Bare ? on std::fs reads: cloud/services/query.rs read_query_sql (~1201); cloud/clickpipes.rs build_kafka_schema_registry (~2968), read_protobuf_schema_file (~2999), build_kafka_source_with_exactly_once (~3050, ~3061), read_gcp_service_account_file (~4789), build_postgres_request (~5479), build_mysql_request (~5716), build_mongodb_request (~5896); cloud/udfs.rs open_artifact (~840) maps the error away.
Expected vs actual
Expected: the error names the path (and ideally the flag) and keeps the OS reason, as cloud postgres query and saved-query already do ('Failed to read SQL file '': '), with FailureKind::Io preserved. Actual: bare OS message, which is ambiguous in commands with several file flags.
Likely cause
The functions above use bare ? on std::fs reads, and open_artifact drops the error. A shared helper (path + error, Io failure kind) would cover them all. Tests should assert the code/failure kind and that the path appears, not prose.
Scores: L=6 I=5
Basis: reproduced (queries-file); validated by source review for the rest.
From the 2026-11-04 user-testing sweep (medium severity): report finding 41. Checked against stack head 6859d2ac (PR 1220).
- Dominant language
- Rust
- Stars
- 80
- Forks
- 9
- Avg merge
- 2d 13h
- Merged PRs (30d)
- 47
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from ClickHouse/clickhousectl
-
cargo audit red on main: RUSTSEC-2026-0387 (crypto-bigint 0.5.5 via aws-config credentials-login)Possibly taken @sdairs claimed this 3 days ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
ClickHouse/clickhousectl#1183 ·
Maintainers usually reply within 1 day
-
Reject empty positional IDs as usage errors instead of sending them to the APIPossibly taken @sdairs claimed this 1 day ago. Openbug cloud
ClickHouse/clickhousectl#1246 · 1 assignee ·
Maintainers usually reply within 1 day
-
AWS backup bucket create cannot succeed in orgs without the external-ID feature (iamRoleExternalId required by the library, rejected by the server)Possibly taken @sdairs claimed this 1 day ago. Openbug cloud
ClickHouse/clickhousectl#1245 · 1 assignee ·
Maintainers usually reply within 1 day
-
clickpipe create kafka/kinesis/pubsub: require --column, as object-storage doesPossibly taken @sdairs claimed this 1 day ago. Openbug cloud
ClickHouse/clickhousectl#1243 · 1 assignee ·
Maintainers usually reply within 1 day
-
clickpipe cdc-scaling update: a single --cpu-millicores or --memory-gb always fails, though help says omitted values are keptPossibly taken @sdairs claimed this 1 day ago. Openbug cloud
ClickHouse/clickhousectl#1242 · 1 assignee ·
Maintainers usually reply within 1 day
All issues in ClickHouse/clickhousectl
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100
nervosnetwork/fiber#1723 ·
Maintainers usually reply within 2 days
-
Difficulty 2/5 1-3 hours Newbie friendliness 69/100
Maintainers usually reply within 1 day
-
needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 71/100
pbakaus/impeccable#1314 ·
Maintainers usually reply within 1 day
-
marmite skill: `curl ... | sh` is the first install method, bypassing review and integrity checksOpen
Difficulty 1/5 1-3 hours Newbie friendliness 78/100
rochacbruno/marmite#565 ·