[openstack-dev] [kolla][release][requirements] providing constraints for transitive dependencies

Tony Breeds tony at bakeyournoodle.com
Mon Nov 28 09:06:16 UTC 2016


On Mon, Nov 28, 2016 at 08:15:17AM +0000, Steven Dake (stdake) wrote:
> Tony,
> 
> Are you indicating that all transitive dependencies (e.g. nova depends on x
> depends on y, y = version of dep we want to specify) are in
> global-requirements.txt?

So in order to reduce confusion I'll try to explain this in a little more
detail but the TL;DR is:

No only nova's direct requirements are in global-requirements.txt.  *all*
requirements are in upper-constraints.txt.

Now the longer version:

 * nova requires oslo.messaging, which is listed in openstack/nova:requirements.txt.
 * openstack/nova:requirements.txt is regularly updated by the proposal-bot with
   the relevant parts of global-requirements.txt
 * the nova project runs the 'check-requirements' jobs ensuring that
   everything in:
    openstack/nova:requirements.txt
    openstack/nova:test-requirements.txt
    and relevant parts of openstack/nova:setup.cfg
   are listed in global-requirements.
 * As oslo.messaging is an OpenStack project it's bound by the same rules above
 * However any non-OpenStack libraries used by either nova or oslo.messaging
   are not in global-requirements.txt.  There is a nightly job that installs
   all of global-requirements.txt (and dependencies) and tracks the exact
   version of each library in a file ... upper-constraints.txt

So anything you need to install to use any part of OpenStack[1] will be listed
in upper-constraints.txt.

So if you really need to install version $x of library $foo you can edit
upper-constraints.txt to state that.

There are a couple of gotchas.  I recommend you use edit-constraints from
openstack-requirements (on pypi) to actually edit the constraints files.  Also if
you're doing anything "too funky" you're probably best actually editing a
requirements and then using generate-constraints to actually generate the
constraints file.  That's time/network expensive but will result in a valid set
where editing the constraints file at will could result in an
incompatible and thus uninstallable system.

I really hope that helps and hasn't just confused the situation.

Yours Tony.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: not available
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20161128/6d48551d/attachment.pgp>


More information about the OpenStack-dev mailing list