Skip to content

Inconsistent behaviour when mixing --continue-at with --no-clobber or --remove-on-error #15645

Closed
@piru

Description

@piru

I did this

$ echo plop > robots.txt
$ curl --no-clobber -C 1 -O https://curl.se/robots.txt

The downloaded content is appended torobots.txt file.

and

echo plop > important
curl --remove-on-error -C 1 -o important https://nonexisting.curl.se/

The file important is removed.

I expected the following

Curl should likely report and error instead of behaving inconsistently, or the documentation should be improved to mention the behaviour in these scenarios.

curl/libcurl version

8.11.0

operating system

Any

Activity

self-assigned this
on Dec 2, 2024
bagder

bagder commented on Dec 2, 2024

@bagder
Member

In the first case with --no-clobber and --continue-at, what could the user possibly want to happen? Is there a legit use case there? Should we make it simple and just deny that option combination?

icing

icing commented on Dec 2, 2024

@icing
Contributor

Since these options are fairly new, I think denying it makes sense.

piru

piru commented on Dec 2, 2024

@piru
Author

I think erroring out is the correct thing to do.

added a commit that references this issue on Dec 2, 2024
0169b80
added a commit that references this issue on Dec 2, 2024
ffbcde0
added 2 commits that reference this issue on Apr 26, 2025
1c08607
d9ddea7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

    Development

    No branches or pull requests

      Participants

      @icing@bagder@piru

      Issue actions

        Inconsistent behaviour when mixing --continue-at with --no-clobber or --remove-on-error · Issue #15645 · curl/curl