Re: Python Egg Draft 3

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Panu Matilainen wrote:
> 
> Separating the namespaces is a fundamental problem for the dependency
> extractor. For provides this is obviously not an issue, but requires
> need to be generated without being able to actually locate (and possibly
> import) the actual module. Python syntax for importing egg- and regular
> modules is the same, so they need to live in the same namespace,
>  otherwise the manual Requires just turn into manual BuildRequires and
> the depency extractor will be just adding syntactic sugar for nothing :)
> 
I think I've figured out a way to make this almost work::
  import sqlalchemy

is equal to Requires python(sqlalchemy)

Any of these::
  __requires__='SQLAlchemy'
  pkg_resources.require('SQLAlchemy')
  requires.txt:
    install_requires = [ 'SQLAlchemy' ]

are equal to python-egg(sqlalchemy)

This breaks down when thinking about what happens in this case::
  __requires__='TurboGears'
  import pkg_requires
  import sqlachemy

At this point you have to know whether TurboGears or anything that it
requires has a requires.txt which includes ['SQLAlchemy'].  If it does
we are using the egg interface to sqlalchemy.  If it doesn't we are
using the normal interface.

So, assuming we remove our patch that stops generation of egg-info files
for distutils generated modules for F9, I agree that there isn't very
much value for quite a bit of work.

-Toshio

Attachment: signature.asc
Description: OpenPGP digital signature

--
Fedora-packaging mailing list
Fedora-packaging@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/fedora-packaging

[Index of Archives]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite Forum]     [KDE Users]

  Powered by Linux