A few months ago I fixed a Rails bug that was yielding weird, unexpected results when parsing form parameter names: effectively HWIA semantics were screwing up UrlEncodedPairParser's parameter parsing when dealing with nested values. This fixed the defect in question -- and thus solved my immediate problem -- it raised wider questions about the actual correctness and behavior of Rails' current parameter parsing code.
A colleague of mine recently ran into a related problem when dealing with collections of records in Rails forms, which prompted me to finally do something about the parameter parsing behavior. Now, while I'm sure we're not the only ones hitting this wall, I'm aware that proposals to change to the parameter parsing semantics in Rails is likely to be met with a little caution, hesitation -- possibly even terror. With that in mind, I've put up a plugin so everybody can give this a go without having to apply any nasty patches:
Please see the README (attached) for the full details.
Be gentle, this is an early release that has been cobbled together over the course of a few nights. We may not have everything right here, but that's why it's being proposed as a plugin rather than yet another issue in the tracker. It's hoped this will yield a wider discussion around the semantics of parameter parsing in core Rails, because -- as it stands -- things can get a little screwy.
Looking forward to your feedback, suggestions and/or patches. If this breaks your code in ways you don't expect, or doesn't quite work how you would like/need it to, or if it's missing a feature that you'd kill to have, I'd love to know.
Please be vocal.
README (2.52 KB)