Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Python: Python

More precise document on os.path.normpath()

 

 

Python python RSS feed   Index | Next | Previous | View Threaded


pengyu.ut at gmail

Nov 23, 2009, 5:52 PM

Post #1 of 4 (191 views)
Permalink
More precise document on os.path.normpath()

After I tried os.path.normpath(), it is clear that the function
doesn't return the trailing '/', if the path is a directory. But this
fact is not documented. Should this be documented in future release of
python.

Also, I found the documentation of some functions in os.path are not
clear. I have to try them in order to understand them for corner
cases. I'm wondering if I can join the people who maintain the
document to help improve it.
--
http://mail.python.org/mailman/listinfo/python-list


benjamin.kaplan at case

Nov 23, 2009, 5:59 PM

Post #2 of 4 (171 views)
Permalink
Re: More precise document on os.path.normpath() [In reply to]

On Mon, Nov 23, 2009 at 8:52 PM, Peng Yu <pengyu.ut [at] gmail> wrote:
> After I tried os.path.normpath(), it is clear that the function
> doesn't return the trailing '/', if the path is a directory. But this
> fact is not documented. Should this be documented in future release of
> python.
>
> Also, I found the documentation of some functions in os.path are not
> clear. I have to try them in order to understand them for corner
> cases. I'm wondering if I can join the people who maintain the
> document to help improve it.
> --

Just file a bug report listing what part you find unclear and what you
suggest they put to clarify it.

> http://mail.python.org/mailman/listinfo/python-list
>
--
http://mail.python.org/mailman/listinfo/python-list


pavlovevidence at gmail

Nov 23, 2009, 6:49 PM

Post #3 of 4 (167 views)
Permalink
Re: More precise document on os.path.normpath() [In reply to]

On Nov 23, 5:59 pm, Benjamin Kaplan <benjamin.kap...@case.edu> wrote:
> On Mon, Nov 23, 2009 at 8:52 PM, Peng Yu <pengyu...@gmail.com> wrote:
> > After I tried os.path.normpath(), it is clear that the function
> > doesn't return the trailing '/', if the path is a directory. But this
> > fact is not documented. Should this be documented in future release of
> > python.
>
> > Also, I found the documentation of some functions in os.path are not
> > clear. I have to try them in order to understand them for corner
> > cases. I'm wondering if I can join the people who maintain the
> > document to help improve it.
>
> Just file a bug report listing what part you find unclear and what you
> suggest they put to clarify it.

The documentation does not and should not try to document every little
detail of every function.

For that matter, nor should comp.lang.python.

Python is open source, anyone can look at the implementation to see
how it behaves. The source code is the right place to seek answers
about arcane minutae like when os.path.normpath appends a backslash.
Not the Python docuementation, and definitely not this newsgroup.


Carl Banks
--
http://mail.python.org/mailman/listinfo/python-list


lie.1296 at gmail

Nov 23, 2009, 7:57 PM

Post #4 of 4 (168 views)
Permalink
Re: More precise document on os.path.normpath() [In reply to]

Peng Yu wrote:
> After I tried os.path.normpath(), it is clear that the function
> doesn't return the trailing '/', if the path is a directory. But this
> fact is not documented. Should this be documented in future release of
> python.
>
> Also, I found the documentation of some functions in os.path are not
> clear. I have to try them in order to understand them for corner
> cases. I'm wondering if I can join the people who maintain the
> document to help improve it.

os.path is designed for OS-agnostic path manipulation. The textual
representation of the output of os.path is irrelevant. If a trailing '/'
doesn't affect the ability to open the directory or file or os.path.join
or whatever, it is irrelevant to os.path. If the trailing / does affect
those abilities, though, it is a bug in os.path.
--
http://mail.python.org/mailman/listinfo/python-list

Python python RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.