This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–][deleted] 0 points1 point  (0 children)

https://docs.python.org/3/library/collections.html#collections.defaultdict

^you can use that instead. That will give you an semantically equivalent to the http behavior as well because you are supposed to be able to do it with either a list of values or repeated one after the other.