[issue26609] Wrong request target in test_httpservers.py

Martin Panter report at bugs.python.org
Sat Apr 2 19:03:16 EDT 2016


Martin Panter added the comment:

Perhaps tempdir_name could get the slash prefixed in setUp() rather than in every test. There is one case that creates index.html which could probably be changed to use self.tempdir, and then the rest could be renamed to say self.base_url.

Rejecting requests that do not start with a slash could be a compatibility problem. Do you think potential security benefits (i.e. having unexpected variations on the format of the URL) outweigh that?

Either way, it would be good to retain a test without a slash.

----------
stage:  -> patch review

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue26609>
_______________________________________


More information about the Python-bugs-list mailing list