Web Design Discussion > General Web Design Discussion

HB: traveler mileage and percent

(1/8) > >>

Jim:
Code addressing the main feature requested in

https://github.com/TravelMapping/Web/issues/218

is now in the HB on tmtest.  Please give it a try.  I think it's pretty straightforward, but I'd like to get a little feedback before going live with it on the production site.

(Grades went in for the semester, and I felt I should knock off at least one item from the TM backlog before taking care of a bunch of other work-related items I have been putting off.)

mapcat:
Found a bug:

http://tmtest.teresco.org/hb/?units=miles&u=mapcat&r=ca.ca163

(I just selected the route at random)

Even though I'm listed among those who have clinched the route, and my length traveled (10.87 mi) equals the total length (also 10.87 mi), my percent traveled is 99.97%.

Similar situation on two more short clinched routes:

http://tmtest.teresco.org/hb/?units=miles&u=mapcat&r=ca.ca056
http://tmtest.teresco.org/hb/?units=miles&u=mapcat&r=ca.ca282

Note that, for CA282, a route clinched by everyone who's driven it, the average traveled is 100.00% even though users are credited with 100.6%.

Longer routes don't have the problem:

http://tmtest.teresco.org/hb/?units=miles&u=mapcat&r=ca.i005
http://tmtest.teresco.org/hb/?units=miles&u=mapcat&r=ca.i010
http://tmtest.teresco.org/hb/?units=miles&u=mapcat&r=ca.i040



Jim:
Ah, a rounding problem.  Thanks for finding it.  I think I've fixed it.

mapcat:
Looks good!

yakra:
Straightforward, and cleanly presented. As @mapcat noted on GitHub, we can compare our percent travelled to the average. I like.

Navigation

[0] Message Index

[#] Next page

Go to full version