Overall, I agree that url handling in the various transports classes may receive some love especially about which encoding is used (including url-escaped) is/should/should not be used by which methods.
It's both amazing and scary that you've been able to fix this bug without touching a single transport test... I understand why but it's still amazing.
A couple of nits:
8 + # Check relative references with absolute paths
17 + # Check relative references with relative paths
29 + # TODO: Check full URLs as well as relative references
33 + # Check relative references with absolute paths
42 + # Check relative references with relative paths
51 + # TODO: Check full URLs as well as relative references
Hmm, do I see a pattern there ?
This screams: split these tests to my ears.
70 + # Segements begin at first comma after last forward slash, if one exists
The comma is easy to miss, the leading paren was clearer to indicate that two values are returned.
Two final notes:
- there has been discussion in the past about never removing the final path from 't.base' as it *is* a directory anyway (and then stop adding it blindly),
- I'd really like to see your mail summarising your thoughts about url handling across the code base ;-D
Thanks for your patience on that.
Overall, I agree that url handling in the various transports classes may receive some love especially about which encoding is used (including url-escaped) is/should/should not be used by which methods.
It's both amazing and scary that you've been able to fix this bug without touching a single transport test... I understand why but it's still amazing.
A couple of nits:
8 + # Check relative references with absolute paths
17 + # Check relative references with relative paths
29 + # TODO: Check full URLs as well as relative references
33 + # Check relative references with absolute paths
42 + # Check relative references with relative paths
51 + # TODO: Check full URLs as well as relative references
Hmm, do I see a pattern there ?
This screams: split these tests to my ears.
70 + # Segements begin at first comma after last forward slash, if one exists
s/Segements/ Segments/
71 + segment_start = lurl.find(",", lurl.rfind("/")+1)
'+1'... Cunning ;) and commented !
74 - return (join(parent_url, subsegments[0]), subsegments[1:]) start], lurl[segment_ start+1: ].split( ",")
75 + return lurl[:segment_
The comma is easy to miss, the leading paren was clearer to indicate that two values are returned.
Two final notes:
- there has been discussion in the past about never removing the final path from 't.base' as it *is* a directory anyway (and then stop adding it blindly),
- I'd really like to see your mail summarising your thoughts about url handling across the code base ;-D
.. and one more thing: news entry