homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ronaldoussoren
Recipients ronaldoussoren
Date 2010年11月12日.15:14:04
SpamBayes Score 1.9366214e-06
Marked as misclassified No
Message-id <1289574847.69.0.366708031395.issue10395@psf.upfronthosting.co.za>
In-reply-to
Content
The documentation for os.path.commonprefix notes:
os.path.commonprefix(list)
Return the longest path prefix (taken character-by-character) that is a prefix of all paths in list. If list is empty, return the empty string (''). Note that this may return invalid paths because it works a character at a time.
And indeed:
>>> os.path.commonprefix(['/usr/bin', '/usr/bicycle'])
'/usr/bi'
This is IMHO useless behaviour for a function in the os.path namespace, I'd expect that os.path.commonprefix works with path elements (e.g. that the call above would have returned '/usr').
History
Date User Action Args
2010年11月12日 15:14:07ronaldoussorensetrecipients: + ronaldoussoren
2010年11月12日 15:14:07ronaldoussorensetmessageid: <1289574847.69.0.366708031395.issue10395@psf.upfronthosting.co.za>
2010年11月12日 15:14:04ronaldoussorenlinkissue10395 messages
2010年11月12日 15:14:04ronaldoussorencreate

AltStyle によって変換されたページ (->オリジナル) /