Strange duplication of dives

Linus Torvalds torvalds at linux-foundation.org
Sun Dec 16 09:51:42 PST 2012


On Sun, Dec 16, 2012 at 9:14 AM, Dirk Hohndel <dirk at hohndel.org> wrote:
>
> The diveid is simply part of the SHA1 hash of the fingerprint of the
> dive. I assume that contains the raw timestamp, correct?

The old dive doesn't have a dive ID at all. Merging them would have
picked the new dive computer information, but because they were far
enough apart, that just didn't happen.

> We used to cut off downloads by saying "this dive was prior to the last
> dive that we already have" - much simpler and certainly prevented what
> happened to you...
>
> Linus, you changed this to the SHA1 logic... any idea why this would fail?

The download matching doesn't actually use the new diveid at all, it
still (and always did) uses the exact divetime.

I guess we should change that, but it doesn't fix David's case, since
he doesn't have that dive ID in his old dive at all. But something
like the attached patch is probably the right thing to do.

               Linus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: patch.diff
Type: application/octet-stream
Size: 1198 bytes
Desc: not available
URL: <http://lists.hohndel.org/pipermail/subsurface/attachments/20121216/399b9399/attachment.obj>


More information about the subsurface mailing list