Extracting information from a webservice

Aurélien PRALONG aurelien.pralong at gmail.com
Wed Jan 23 06:27:43 PST 2013


Looks very complicated. Shouldn't we use a dedicated PK in the DB (with
auto increment) and return this ID in the webservice ?

Aurélien

2013/1/23 Dirk Hohndel <dirk at hohndel.org>

> To make this a little easier to envision, here's a trivial hack that
> actually parses the data downloaded from the webservice (without
> attempting to fix the incorrect "middle of the night" timestamps
> mentioned above - you can just edit the timestamps once the "dives" are
> imported).
>
> Because the times are not close enough to the real dives I didn't expect
> this to simply match the dives that I have. And looking a little more
> closely, the "likely_same_dive" logic calls dives different because the
> imported dives have no depth and duration (and are therefore different).
> Also, try_to_merge isn't even called if dives don't overlap (completely
> reasonable for "real" dives).
>
> So there are a few more hacks involved here, but nonetheless, this does
> get me GPS locations for the dives that I have tracked with the
> Subsurface Companion App :-)
>
> So no - this is not the somewhat more fancy "help the user match"
> algorithm envisioned above. This simply loads the gps information from
> the webservice and tries to match it with 20 minutes fuzz into the
> existing dives - which catches at least some of my dives and shows that
> this could work as a proof of concept.
>
> I'm running out of time (I tried to fight insomnia for a few hours
> before getting up... should have just given up on sleep when I
> originally woke up at 1:45am), but I'll try to create a few dummy
> entries on the webservice that use the key included in the sources and
> that match test dives... this way hopefully more people can play with
> this.
>
> /D
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.hohndel.org/pipermail/subsurface/attachments/20130123/46134f32/attachment.html>


More information about the subsurface mailing list