Stuart Bishop wrote:
From reading section 4.2 of , I
suspect the best way of handling this situation is to concatenate the
duplicate headers into a comma seperated string.

In fact, section 4.2 seems to suggest that proxies are allowed to combine headers using commas. Thanks for discovering that. In light of this, I think it would be better to generate a comma-separated string, as you suggest, rather than interpret overloaded headers as a list. Using a list is more obvious, but seems quite fragile, since code in random places would have to be prepared to accept either a string or a list. isinstance() cruft would appear.

Thinking more... the request should provide two methods, one for retrieving a header value as a string (possibly comma-concatenated), and another for retrieving a header value as a list.

Zope3-dev mailing list

Reply via email to