[openstreetmap/openstreetmap-website] Problems with the way#test_max_nodes_per_way_limit (#1516)

Matt Amos notifications at github.com
Wed Apr 5 12:54:03 UTC 2017


I have a hazy memory that the code was originally written to make ways with large numbers of nodes invalid, but such ways exist in the history and _were_ valid when they were created. So the code was changed to validate new versions of ways only with `preconditions_ok?`.

I think it would be better to do it with `valid?` on the model, as that seems more likely to give us universal coverage of all code paths. It's possible that, by now, no current version of any way would have an invalid number of nodes, so this could be on `Way` and left off `OldWay`?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/issues/1516#issuecomment-291852059
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20170405/a1b1f6d9/attachment.html>


More information about the rails-dev mailing list