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 ezio.melotti
Recipients ezio.melotti, markon, ronaldoussoren, strank, wrstlprmpft
Date 2009-10-18.17:42:06
SpamBayes Score 0.0009208423
Marked as misclassified No
Message-id <1255887728.64.0.222566181506.issue1646838@psf.upfronthosting.co.za>
In-reply-to
Content
realpath is only supposed to return an absolute pathname, resolving '.',
'..' and symlinks. It's not its duty to expand '~', therefore in your
example

> In [3]: path.realpath('~')
> Out[3]: 'C:\\Dokumente und Einstellungen\\wrstl\\~'

the '~' is seen as a normal file and the cwd is used to create the
absolute path to it (on Windows realpath is the same as abspath, on
Linux realpath calls abspath when there's nothing to resolve, so the
result is the same -- i.e. cwd + filename).


realpath needs better tests and documentation though, but this can be
addressed in #6975, so I'm closing this.
History
Date User Action Args
2009-10-18 17:42:09ezio.melottisetrecipients: + ezio.melotti, ronaldoussoren, wrstlprmpft, strank, markon
2009-10-18 17:42:08ezio.melottisetmessageid: <1255887728.64.0.222566181506.issue1646838@psf.upfronthosting.co.za>
2009-10-18 17:42:07ezio.melottilinkissue1646838 messages
2009-10-18 17:42:06ezio.melotticreate