Skip to content

Should the form dialect be recursive? #1

@jdp

Description

@jdp

The default form encoding from urllib.urlencode doesn't support multi-dimensional values. That behavior can be taken from the multidimensional-urlencode package:

>>> import urllib
>>> from multidimensional_urlencode import urlencode
>>> e = urlencode({"a": {"b": {"c": [1, 2, 3], "d": "e"}}})
>>> urllib.unquote(e)
'a[b][d]=e&a[b][c]=1&a[b][c]=2&a[b][c]=3'

Should it be part of the default form dialect, or should there be a separate dialect for multidimensional values?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions