bug-wget
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug #62795] Distinguish between error codes


From: Darshit Shah
Subject: [bug #62795] Distinguish between error codes
Date: Sat, 22 Oct 2022 15:41:56 -0400 (EDT)

Update of bug #62795 (project wget):

                  Status:                    None => Invalid                
             Open/Closed:                    Open => Closed                 

    _______________________________________________________

Follow-up Comment #1:

Hi,

the issue here is that there seems to be a misunderstanding of the -O option.
-O is meant to act like shell redirection, i.e. the following are meant to be
identical

$ wget example.com -O- > file.html
$ wget example.com -O file.html


Which means that the file will ideally be truncated before the download even
starts and thus *MUST* always be fully redownloaded. We've tried to add some
checks here and there to protect from footguns and what you're seeing is one
of them. You asked to never clobber any files and then used -O which would
immediately clobber it. 

Even if we were to add the option as you requested, it would not be useful
since it would only check if a file by that name exists. If you really want to
check that it is the same file as on the server you must unfortunately remove
the -O option.

I know this is not ideal and not the answer you wanted to hear. But I'm stuck
in a hard place. This is documented behaviour for about 25 years and I cannot
just change it, it would break a huge number of scripts. 


    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?62795>

_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]