?

Log in

No account? Create an account
brad's life [entries|archive|friends|userinfo]
Brad Fitzpatrick

[ website | bradfitz.com ]
[ userinfo | livejournal userinfo ]
[ archive | journal archive ]

overwrite this file stupidity [Jun. 28th, 2005|08:52 pm]
Brad Fitzpatrick
[Tags|]

So I'm moving around some pictures locally, dropping some into a folder which I apparently had already copied some into.

It brings up this great dialog, asking:

Do you really want to overwrite this file?

And underneath it:

-- shows they have the same modtime
-- same size
-- and renders thumbnails of them both (and they're the same)

Okay, Mr. Program, maybe they're actually the same and you don't need to ask me. You obviously read the damn thing in to make the thumbnail, so you could've just hashed the file. And even if you got it from cache/exif, you know the size of it (and it's small, being a camera phone pic), so you could've read and hashed them in less time than I did clicking a confirm button.

*shrug*
LinkReply

Comments:
[User Picture]From: remark
2005-06-29 03:58 am (UTC)
Think of it this way: no matter which option you choose, you can't be wrong!
(Reply) (Thread)
[User Picture]From: maxvt
2005-06-29 06:54 am (UTC)
Considering how often an average user clicks "yes" on this and similar boxes before understanding what they actually say... definitely should get rid of 'confirm' dialogs.
(Reply) (Thread)
[User Picture]From: crschmidt
2005-06-29 09:49 am (UTC)
I'd be concerned that a hash collision would occur, and that I'd overwrite ExtremelyImportant.pdf with ReallyCrappy.pdf. The chances it would happen are miniscule, but Murphy says it'll happen eventually.
(Reply) (Thread)
[User Picture]From: jgrafton
2005-06-29 10:21 am (UTC)
But what if they both happen to be [different] postscript files that hash to the same thing?

I guess this happens fairly rarely, though.
(Reply) (Thread)
[User Picture]From: revjim
2005-06-29 05:11 pm (UTC)
Fuckin' A!

I've been thinking this for years. How hard it is to actually let a computer COMPUTE once in a while?!

If you really are worried that it's a bad thing to do, make a back up with an easy way to restore and a time limit on how long the backup will be kept around.
(Reply) (Thread)
From: evan
2005-06-29 05:26 pm (UTC)
file a bug report!
(Reply) (Thread)
[User Picture]From: rustydragon
2005-06-30 02:41 pm (UTC)
For copying your proposal looks ok.
Summarizing, you propose to "click" on "no" button if files are identical.
But what about move operation?
Keeping in mind that Move = Copy + Delete
Well, clicking "no" will not lead us to what we really want in this case, because file will not be deleted.
(Reply) (Thread)