Working Group Minutes/EWG 2014-01-20

Attendees

IRC nick Real name
gravitystorm Andy Allan
pnorman Paul Norman
RichardF Richard Fairhurst
shaunmcdonald Shaun McDonald
TomH Tom Hughes
zere Matt Amos

Summary

  • Routing branch
    • RichardF offered to have a look. The current "routing2" branch needs updating to a current version of the rails port, or rewriting against it.
    • For geocoding, results go through rails, but this should be unnecessary for routing.
    • Although, worth noting that it might be good to hide API keys and so forth.
  • Groups
    • RichardF has been working on this, but struggling with pagination. Everyone agreed that pagination is a pain in rails.
    • shaunmcdonald wondered if we should abstract our logic out to make a pagination plugin that doesn't get the full count (to avoid performance problems)? If anyone is looking for a small/medium problem to solve, this would fit the bill.

IRC Log

17:31:22 <zere> minutes of the last meeting: http://www.osmfoundation.org/wiki/Working_Group_Minutes/EWG_2014-01-13 please let me know if anything needs fixing.
17:31:56 * pnorman waves
17:32:05 <zere> going through actions from meetings passim; i had one to set up a mailing list for people to contact EWG - apologies, but that's not done yet. i'll get on it this week.
17:32:23 <zere> the blog post will be published imminently, hopefully.
17:33:01 <zere> other than that, there's nothing carried over from last week.
17:33:11 <zere> so is there anything anyone wanted to discuss?
17:33:30 <pnorman> We need to put the routing branch back on the agenda
17:34:08 <pnorman> but perhaps discuss that when apmon is here?
17:34:19 * pnorman was about to go for breakfast too
17:37:15 <zere> yup, i can put it on the agenda for next week, and fingers crossed he'll be around then.
17:37:40 <zere> perhaps we can discuss it even if he isn't - if anyone's willing to take a poke through the branch and see what state it's in?
17:38:19 <gravitystorm> always good to have a bus_number > 1
17:39:06 <RichardF> where is the routing branch?
17:40:10 <zere> is it this one? https://github.com/apmon/openstreetmap-website/tree/routing2
17:40:30 <RichardF> "[temporary] Use OpenLayers.js from openlayers.org"
17:40:50 <RichardF> if it's still on OL, that suggests there may not be a whole bunch to keep... :(
17:41:34 <zere> yup - that's the branch which is up on dev, according to the chef repo.
17:41:53 <zere> and yeah "42 commits ahead and 1748 commits behind master"
17:42:08 <zere> indicates the first bit of work that has to be done ;-)
17:42:24 <RichardF> oh lawdy.
17:43:10 <gravitystorm> that's a lotta commits
17:43:22 <shaunmcdonald> last commit authored 2 years ago, so might need a rewrite with all the changes since then.
17:43:51 * RichardF clicks "Routing" repeatedly at http://routing.apis.dev.openstreetmap.org/
17:44:15 <RichardF> I think we might be looking at a rewrite situation here.
17:45:35 <shaunmcdonald> I can't approve the cycle routing, as it's too dangerous taking you on main roads, instead of cycle routes.
17:47:10 <gravitystorm> RichardF: https://github.com/apmon/openstreetmap-website/compare/routing2 has a "files changed" tab that gives a good overview of what's in there. A lot of icons, some various config stuff, a fair bit of ruby and a fair bit of js
17:47:47 <gravitystorm> I suspect a lot of the js will need redoing for sidebar/leaflet, but some of the routing-service-abstraction ruby code would still be valid
17:47:51 <RichardF> gravitystorm: ah, interesting. thank you.
17:48:25 <RichardF> not entirely sure what needs to be done in Ruby - what does that gives us that a pure-JS solution doesn't?
17:48:45 <zere> presumably, a lot of the UI has to be re-jiggered or re-written due to leaflet and the new design... but RichardF, you're really awesome at that! and i will buy you cider! ;-)
17:48:46 <gravitystorm> keeps our cloudmade API key secret, if nothing else :-)
17:48:50 * RichardF laughs
17:49:21 <RichardF> zere: if you'd said "and I will finish the Hard Rails Bits of the groups branch!" then I might be convinced ;)
17:49:37 <gravitystorm> https://github.com/apmon/openstreetmap-website/blob/9755c3ae0a8d0684d43760f91dc864ff42d8477a/app/controllers/routing_controller.rb is the meat-and-potatoes bit of the code, by the looks of things
17:49:43 <RichardF> because I'd _really_ like to get groups working, but there are things there that are beyond me
17:50:26 <zere> i think it's that way because it's "the same" with the geocoding (i.e: going via Rails), but i'm not entirely sure. presumably things like app keys are worth keeping secret, but there's definitely a trade-off when channelling all that traffic via the site.
17:50:36 <RichardF> gravitystorm: wugh. really don't see why that has to go through Rails.
17:50:54 <zere> RichardF: "and I will finish the Hard Ale Bits of the groups branch" perhaps...
17:51:47 <RichardF> better to have something pluggable in JS, so we have (say) a CM routing connector, and an OSRM routing connector (etc.) which just take the data returned by the services, reformat it, and send it to the JS code for display.
17:55:44 <zere> i can't remember the reasoning behind "goes-via-rails"... if TomH is around, perhaps he remembers better. i don't think it was to do with the API key... more that it was to shield us from upstream flakiness (i think?)
17:55:49 <gravitystorm> RichardF: It's probably 6 of one. But since geocoding_controller exists and provides a similar service, given the choice I'd do the same with routing_controller. Unless we hear from Higher Powers (TomH) that geocoding_controller needs refactoring...
17:56:20 <TomH> sorry, only just joined (forgot about meeting)
17:57:08 <TomH> I wrote geocoding controller liker that because (a) we needed multiple sources back then and (b) I had no idea what I was doing AJAX wise
17:57:29 <TomH> these days I would no doubt do it client side
17:57:49 <zere> fair enough. so there's no reason to make routing go via a rails controller.
17:58:04 <RichardF> ok.
17:59:35 <zere> RichardF: speaking of groups - what needs to be done on that?
17:59:57 <gravitystorm> sorry all, got to go.
18:00:44 <zere> (btw, http://blog.openstreetmap.org/2014/01/20/hack-weekend-december-2013/ is live now)
18:01:18 <RichardF> zere: a few little things. I ran into a brick wall when it came to the pagination - stuff like the group page was meant to display the last 10 diary entries for the group, but when I tried to find out how pagination worked on osm.org, I got lost in a maze of twisty little passages, all alike.
18:01:41 <RichardF> and, of course, the code is (just) pre-redesign, so will probably need a bit of fettling to bring it up-to-date.
18:02:03 <RichardF> if it helps, I can try and co-ordinate a list of what still needs doing - I think we had one in the past.
18:02:10 <TomH> og pagination is a nightmare
18:02:12 <zere> yeah, i'm not sure i understand pagination either
18:02:16 <TomH> everything does it differently
18:02:48 <zere> is there a One True Way to do it, and they've all been written at different times, or is there no unified way to do pagination?
18:03:13 <TomH> well we originally used the rails builting in pagination but that was ripped out in rails 3
18:03:34 <TomH> so some stuff still does that, using the classic_pagination plugin that is basically the ripped out rails code
18:03:46 <TomH> and other stuff just does it by hand, often for performance reasons
18:03:47 <RichardF> I kept encountering things like diary_entry_partial and diary_entries_partial and diary_entry_index_partial and about 800 others, all nested. (may be slightly exaggerating)
18:03:52 <zere> i assume there are umpteen plugins to do it, though?
18:03:56 <TomH> because pagination is fundamentally a performance horror
18:04:14 <TomH> yes there are but most of them don't scale
18:04:37 <TomH> because they want to count the total records
18:06:33 <shaunmcdonald> zere: could you give the blog post a category please? (I'd like to avoid uncategorised).
18:07:52 <shaunmcdonald> I wonder if we should abstract our logic out to make a pagination plugin that doesn't get the full count? Thus making it easier to get consistency?
18:08:37 <zere> shaunmcdonald: party, workshops - although that's not really very accurate... perhaps i should have added a "hackday" category...
18:08:42 <TomH> sure, somebody just needs to do the work
18:10:28 <shaunmcdonald> If only time grew on trees ;-)
18:11:29 <zere> shaunmcdonald: thyme grows on bushes - is that close enough? ;-)
18:11:47 <shaunmcdonald> if only ;-)
18:19:49 <zere> was there anything else anyone wanted to discuss?
18:21:55 <shaunmcdonald> not from me.
18:22:32 <zere> ok. thanks to everyone for coming & hope to see you again next week :-)