[Bug 1715481] [NEW] wget -N ignores file size differences
Andrew
publicface at bak.rr.com
Wed Sep 6 20:01:40 UTC 2017
Public bug reported:
The man page states:
"The time-stamping in GNU Wget is turned on using ‘--timestamping’
(‘-N’) option, or through timestamping = on directive in .wgetrc. With
this option, for each file it intends to download, Wget will check
whether a local file of the same name exists. If it does, and the remote
file is not newer, Wget will not download it.
If the local file does not exist, or the sizes of the files do not
match, Wget will download the remote file no matter what the time-stamps
say. "
Note the last sentence carefully: "...the sizes of the files do not
match... no matter what the timestamps say."
To duplicate:
wget -N <remote file>
cp /dev/null <remote file that is now local>
wget -N <remote file>
~~~~~~~~~~~~~~~~~~~~~~~~
Note, it will state "HTTP request sent, awaiting response... 304 Not Modified
File ‘<remote file>’ not modified on server. Omitting download.
Obviously the sizes of the files do not match and it should download the
file. You can also edit the file and manually delete (or add I suppose)
a few lines.
Not related, however I would like to also point out that if I change the
string "$1000" to "$4000" in a document on the remote, the size of the
file does not change, however the files and data are clearly different.
This case usage would break anything depending on actual changes. Such
as automatically getting a vendor's price lists, not just changes to
what is essentially the outer envelope of the file. Kind of important,
no?
ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: wget 1.17.1-1ubuntu1.2
ProcVersionSignature: Ubuntu 4.4.0-93.116-generic 4.4.79
Uname: Linux 4.4.0-93-generic x86_64
ApportVersion: 2.20.1-0ubuntu2.10
Architecture: amd64
CurrentDesktop: Unity
Date: Wed Sep 6 12:42:20 2017
InstallationDate: Installed on 2016-09-11 (359 days ago)
InstallationMedia: Ubuntu 16.04.1 LTS "Xenial Xerus" - Release amd64 (20160719)
SourcePackage: wget
UpgradeStatus: No upgrade log present (probably fresh install)
** Affects: wget (Ubuntu)
Importance: Undecided
Status: New
** Tags: amd64 apport-bug xenial
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to wget in Ubuntu.
https://bugs.launchpad.net/bugs/1715481
Title:
wget -N ignores file size differences
Status in wget package in Ubuntu:
New
Bug description:
The man page states:
"The time-stamping in GNU Wget is turned on using ‘--timestamping’
(‘-N’) option, or through timestamping = on directive in .wgetrc. With
this option, for each file it intends to download, Wget will check
whether a local file of the same name exists. If it does, and the
remote file is not newer, Wget will not download it.
If the local file does not exist, or the sizes of the files do not
match, Wget will download the remote file no matter what the time-
stamps say. "
Note the last sentence carefully: "...the sizes of the files do not
match... no matter what the timestamps say."
To duplicate:
wget -N <remote file>
cp /dev/null <remote file that is now local>
wget -N <remote file>
~~~~~~~~~~~~~~~~~~~~~~~~
Note, it will state "HTTP request sent, awaiting response... 304 Not Modified
File ‘<remote file>’ not modified on server. Omitting download.
Obviously the sizes of the files do not match and it should download
the file. You can also edit the file and manually delete (or add I
suppose) a few lines.
Not related, however I would like to also point out that if I change
the string "$1000" to "$4000" in a document on the remote, the size of
the file does not change, however the files and data are clearly
different. This case usage would break anything depending on actual
changes. Such as automatically getting a vendor's price lists, not
just changes to what is essentially the outer envelope of the file.
Kind of important, no?
ProblemType: Bug
DistroRelease: Ubuntu 16.04
Package: wget 1.17.1-1ubuntu1.2
ProcVersionSignature: Ubuntu 4.4.0-93.116-generic 4.4.79
Uname: Linux 4.4.0-93-generic x86_64
ApportVersion: 2.20.1-0ubuntu2.10
Architecture: amd64
CurrentDesktop: Unity
Date: Wed Sep 6 12:42:20 2017
InstallationDate: Installed on 2016-09-11 (359 days ago)
InstallationMedia: Ubuntu 16.04.1 LTS "Xenial Xerus" - Release amd64 (20160719)
SourcePackage: wget
UpgradeStatus: No upgrade log present (probably fresh install)
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/wget/+bug/1715481/+subscriptions
More information about the foundations-bugs
mailing list