Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion os.path.commonpath()
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
David Townshend  
View profile  
 More options Nov 7 2012, 1:01 am
From: David Townshend <aquavita...@gmail.com>
Date: Wed, 7 Nov 2012 07:59:49 +0200
Local: Wed, Nov 7 2012 12:59 am
Subject: Re: [Python-ideas] os.path.commonpath()

This seems to be overlapping quite a lot with the recent discussion on
object-oriented paths (
http://mail.python.org/pipermail/python-ideas/2012-October/016338.html) and
this question of how paths are represented on different systems was
discussed quite extensively.  I'm not sure where the thread left off, but
if PEP 428 is still going ahead then maybe this is something that should be
brought into it.

David

On Wed, Nov 7, 2012 at 7:15 AM, Greg Ewing <greg.ew...@canterbury.ac.nz>wrote:

> Bruce Leban wrote:

>  If you change the semantics so that it either (1) it always always
>> includes a trailing / or (2) it includes a trailing slash if the two paths
>> have it in common, then you don't have the weirdness that in this case it
>> returns a slash and in others it doesn't. I am slightly inclined to (1) at
>> this point.

> But then the common prefix of "/a/b" and "/a/c" would be "/a/",
> which would be very unexpected -- usually the dirname of a path is
> not considered to include a trailing slash.

> The special treatment of the root directory is no weirder than it
> is anywhere else. It's already special, since in unix it's the
> only case where a trailing slash is semantically significant.
> (To the kernel, at least -- a few command line utilities break this
> rule, but they're screwy.)

> --
> Greg

> ______________________________**_________________
> Python-ideas mailing list
> Python-id...@python.org
> http://mail.python.org/**mailman/listinfo/python-ideas<http://mail.python.org/mailman/listinfo/python-ideas>

_______________________________________________
Python-ideas mailing list
Python-id...@python.org
http://mail.python.org/mailman/listinfo/python-ideas


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.