Skip to content

Path parameter having special characters like brackets and parentheses is not encoded properly in retrofit2 #4312

Description

@kirangodishala

I am from Spinnaker community. We have recently migrated some of our services from retrofit1 to retrofit2. We have hundreds of apis overall.
After migration we are facing challenges with path parameter encoding.

With retrofit1, the path param [foo] b:ar (baz) used to be encoded to %5Bfoo%5D%20b%3Aar%20%28baz%29 and api has no issues.
But after migrating to retrofit2, the encoded value became [foo]%20b:ar%20(baz) and api rejects it with 400.

Is there any plan to fix this issue? What is the work around you suggest?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions