At 02:50 AM 9/12/2009 +0200, Tarek Ziadé wrote:
it means that we can even provide an XML-RPC service at PyPI so people can query the metadata for their platform with zero download and zero third-party code execution.
Ah, now that does sound rather useful, as it would allow installation and similar tools to resolve dependencies without first needing to build or download binaries.
I can see a use case of the configure.py file you are describing: prepare the compilation some C Extensions by looking for some libs etc,
But that's something that can already be done with setup.py when you build or install the distribution.
So what would be the metadata field that would require to look for a library location ?
I had in mind that if you had such a configure script, it could also generate a manifest of files to be installed, e.g. translation files, docs, data, scripts, etc., for the use of a simplified installer system. (Ala the BUILDS proposal of about a year ago.)
On Fri, 11 Sep 2009 18:57:28 -0700, P.J. Eby pje@telecommunity.com wrote:
At 02:50 AM 9/12/2009 +0200, Tarek Ziadé wrote:
it means that we can even provide an XML-RPC service at PyPI so people
can query the metadata for their platform with zero download and zero
third-party
code execution.
Ah, now that does sound rather useful, as it would allow installation
and similar tools to resolve dependencies without first needing to build
or download binaries.
Yes, it is useful. PyPM relies on this 'static metadata', as fetched from
PKG-INFO and requires.txt, before building the packages (on the backend
server). If the package developer used a configure.py like mechanism to
conditionally generate this PKG-INFO or requires.txt before uploading
the tarball, then PyPM will use that metadata for all of the platforms
... which is not we want.
I'm +1 on Tarek's proposal actually .. although Jim Fulton has a point
regarding having conditionals in setup.cfg.
Regardless of the specifics, installer tools should be able to query the
metadata for a given system (not current system). For example, one should
be able to do something like this on Linux and Python-2.6:
metadata = read_metadata('/path/to/source') metadata.get_install_requires_for(pyver=(2,5), osname='win32')
And this should happen without any execution of setup.py.
-srid