Skip to content

Conversation

@pietern
Copy link
Collaborator

@pietern pietern commented Feb 7, 2025

Only -f and -S are new.

Both these new flags could potentially have surfaced an underlying issue in databricks/cli#2307.

With this change, all curl invocations in this repo use the same set of flags.

Description:

  • -f / --fail
    Silently fails on HTTP errors (e.g., 404, 500). Prevents output of error pages to stdout/stderr, returning exit code 22 instead. Critical for scripting to avoid processing invalid responses.

  • -s / --silent
    Suppresses progress meters, error messages, and other non-essential output. Ensures clean output for piping or saving to files.

  • -S / --show-error
    Overrides -s to display errors if they occur. Balances silent operation with actionable error reporting.

  • -L / --location
    Follows HTTP redirects (3xx responses). Essential for URLs that point to mirrored or updated resources (e.g., download links that redirect to CDNs).

@pietern pietern merged commit ed70ee3 into main Feb 7, 2025
15 checks passed
@pietern pietern deleted the curl-fail-on-error branch February 7, 2025 16:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants