send array is not the same behavior as retrofit
when sending @Field("preferences[]") List<int> preferences
chopper sends:
{ "preferences[]":[2000008,2000149] }
retrofit sends:
{ "preferences[]":2000008, "preferences[]":2000149 }
in my app, I depend on this default behavior
take a look at: https://stackoverflow.com/questions/53832007/how-to-send-liststring-with-retrofit
From what I see on Retrofit, it is not possible on FormUrl (and probable json) encoded data and I don't see a way to do it with http package in dart since body is based on HashMap.
But it should be possible for Multipart request
Yes, you are right, I was thinking in chopper @Field works with Multipart.
Stale issue message
Related to following PR in http package https://github.com/dart-lang/http/pull/278
What should we do with this issue?
The referenced PR in http is pretty much neglected since Jun 18, 2019... :/
Indeed, maybe we should start investigate on how to do it on chopper side
Fixed in https://github.com/lejard-h/chopper/pull/439