[Python-ideas] os.path.join
anatoly techtonik
techtonik at gmail.com
Thu Oct 31 11:24:19 CET 2013
On Wed, Oct 30, 2013 at 7:50 PM, Geoffrey Spear <geoffspear at gmail.com> wrote:
> On Wed, Oct 30, 2013 at 12:34 PM, anatoly techtonik <techtonik at gmail.com> wrote:
>> >>> os.path.join('/static', '/styles/largestyles.css')
>> '/styles/largestyles.css'
>>
>> Is it only me who thinks that the code above is wrong?
>
> No, the code is obviously wrong. What's your idea? To make the bit
> about absolute paths in the documentation all bold, red, and blinking?
No. This won't help. The idea is to fill request for a change in
behavior for future versions of Python. With rename if necessary.
Perhaps even for this - http://www.python.org/dev/peps/pep-0428/
And also the idea is to listen to arguments to protect current behavior.
And also what do people think about a library with cross-platform path
operations behavior. Meaning that given all set of paths available on
internet, this library will normalize operations with those paths, and
will provide path handling rules (functions) that work identically on
every platform. In cases where it is impossible, the documentation
will contain description of the problem.
--
anatoly t.
More information about the Python-ideas
mailing list