OpenAnything

Paul Boddie paul at boddie.org.uk
Fri Sep 18 00:12:15 CEST 2009


On 17 Sep, 23:24, kj <no.em... at please.post> wrote:
> In Dive Into Python, Mark Pilgrim offers the function openAnything
> that can open for reading "anything" (i.e. local files or URLs).
>
> I was wondering if there was already in the standard Python library
> an "official" version of this, that could not only open (for reading)
> regular files and URLs, but also other data sources such as compressed
> files.

Not in the standard library, but available from the package index:

http://pypi.python.org/pypi/desktop

The desktop.open function just wraps other mechanisms for opening/
launching files or URLs.

Paul



More information about the Python-list mailing list