killbill / killbill-admin-ui

Kill Bill Administrative UI engine
https://killbill.io
MIT License
52 stars 59 forks source link

Issue 120 Fix bug cannot create Tag Definitions #386

Closed tungleduyxyz closed 9 months ago

tungleduyxyz commented 9 months ago

The issue raised here: https://github.com/rack/rack/issues/2128 I found that the issue comes from the rack gem, the parse_nested_query function. The Gemfile from killbill-admin-ui: gem 'rails', '~> 7.0.1' -> rails 7.0.8 -> will install rack 2.2.8 The Gemfile from killbill-admin-ui-standalone: gem 'rails', '~> 7.0.0' -> rails 7.1.2 -> will install rack 3.0.8 You can compare the parse_nested_queryhere:

Here is our raw source data for POST:

authenticity_token=1cC60RSAumGOde_9icOPLNwLOUroWsWAb7mmqI6S6McpehjcvoKr8p57qivQd_F3DyHjrcGyksSXaq2EWrPEhg&t
ag_definition%5Bid%5D=&tag_definition%5Bapplicable_object_types%5B0%5D%5D=SUBSCRIPTION&tag_definition%5Bname%5D=test1&tag_definition%5Bdescription%5D=te
st1&commit=Save

And the result when using Rack::Utils.parse_nested_query:

Rack 3.0 no longer supports parsing nested params like a[b[c]], the correct nested params should be a[b][c].