so params[:foo] is being populated partially from parameters in the
URL, partially from form parameters ? Some of the parameter parsing
stuff changed in 2.3.2 so if you are using 2.3.2 would be interesting
to see if this is a regression.
Now that I’ve done a bit more testing, I think this is simply a
namespace collision. I think that query parameters and form parameters
share a namespace (the request), and it’s reasonable to have weird or
undefined behavior when there is a collision. It seems like Rails
behavior is to handle the form params first, putting them in the
‘params’ hash, then handle the query params. The Hash class’ behavior
would dictate a ‘last in wins’ behavior, which is consistent with what
I’m seeing.
I found that I don’t really have to encode that parameter in the URL,
which solves my immediate problem.
Thanks!
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.