Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Thomas Goirand



On 04/20/2015 12:10 PM, Victor Stinner wrote:

If there's nothing majorly wrong mid-L, I'd like to release 1.0.0 just
to get us into 'ok its stable' mentality.


I read that many packages modify the source code of libraries and
applications to avoid a dependency to pbr at runtime. What's the
status of this issue? Is pbr still used/required to get the version
of a package a runtime?


Yes, a lot. And even worse: in many cases, pbr isn't even declared in 
the requirements.txt, and I had to double check for the facts myself.



I'm not sure that it's an issue in pbr itself. Maybe applications
should be fixed instead.


The issue is that nobody used oslo.version, and it vanished. Anyway, pbr 
is actually very small, so I don't think it's an issue.


On 04/20/2015 02:22 PM, Victor Stinner wrote:
 I read somewhere that pkg_resources may also be used to get the
 version.

That's correct, and I don't understand why we're not using that.

On 04/20/2015 09:25 PM, Robert Collins wrote:
 Firstly, pbr has no runtime dep on pip - it doesn't import it. So you
 don't need pip installed when an installed package uses pbr to get its
 version.

Why does requirements.txt of PBR has pip then?

Cheers,

Thomas Goirand (zigo)

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Robert Collins
On 21 April 2015 at 09:27, Thomas Goirand z...@debian.org wrote:


 On 04/20/2015 12:10 PM, Victor Stinner wrote:

 If there's nothing majorly wrong mid-L, I'd like to release 1.0.0 just
 to get us into 'ok its stable' mentality.


 I read that many packages modify the source code of libraries and
 applications to avoid a dependency to pbr at runtime. What's the
 status of this issue? Is pbr still used/required to get the version
 of a package a runtime?


 Yes, a lot. And even worse: in many cases, pbr isn't even declared in the
 requirements.txt, and I had to double check for the facts myself.

 I'm not sure that it's an issue in pbr itself. Maybe applications
 should be fixed instead.


 The issue is that nobody used oslo.version, and it vanished. Anyway, pbr is
 actually very small, so I don't think it's an issue.

 On 04/20/2015 02:22 PM, Victor Stinner wrote:
 I read somewhere that pkg_resources may also be used to get the
 version.

 That's correct, and I don't understand why we're not using that.

 On 04/20/2015 09:25 PM, Robert Collins wrote:
 Firstly, pbr has no runtime dep on pip - it doesn't import it. So you
 don't need pip installed when an installed package uses pbr to get its
 version.

 Why does requirements.txt of PBR has pip then?

Because if you do 'python setup.py install' in a pbr repo it will
*run* pip today to install requirements.
But this doesn't apply to packagers, because they will be using the overrides.
The packaging of pbr on a distro that doesn't package pip should just
ignore that requirement today.

In future - 0.12 probably - we'll remove that entry from
requirements.txt, but we need to get a release of master done first.
-Rob

-- 
Robert Collins rbtcoll...@hp.com
Distinguished Technologist
HP Converged Cloud

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Ihar Hrachyshka
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

On 04/20/2015 02:22 PM, Victor Stinner wrote:
 I believe Redhat patch it out. I don't think they should need
 to, since we have explicit knobs for distros to use.
 
 pbr pulls pip which we don't want in RHEL. Example of patches in
 RDO:
 
 https://github.com/redhat-openstack/nova/commit/a19939c8f9a7b84b8a4d71
3fe3d26949e5664089

 
https://github.com/redhat-openstack/python-keystoneclient/commit/e02d529
a87aef8aaca0616c8ee81de224bf1f52a
 https://github.com/redhat-openstack/neutron/commit/85302b75362df302703
83e3a373e60e81b1b2384

 
(well, it's always the same change)

AFAIK Delorean (aka RDO/master) stopped doing it. The approach remains
for RHEL-OSP to avoid python-pbr (and python-pip) dependencies. That
said, I am not sure we should do it in RHEL-OSP too. If RHEL does not
want to see python-pip in their repos, then RHEL-OSP could ship it
with its repositories (?).

I think you should reach Alan Pevec on the matter since he is involved
in pbr cleanup.

/Ihar
-BEGIN PGP SIGNATURE-
Version: GnuPG v2

iQEcBAEBCAAGBQJVNPOfAAoJEC5aWaUY1u57HqUIALdQ+GsUQA9Nc+0nLuUBLM49
nOQtsIqp8giNfO2o897ll1uM93VD4io5fLXaNrp6K7jKba6e6bjlCRPjybuwbAQD
gNrfZzB4ZAUMVDj4o4Ftl/kwnS1ijx1EoRV/D7YWgzU0VF//qVyBHxZNv8+TdV/U
pF/ij5ZJi5TdnBO8QpIo91GmEFvR0ibhWNxCoEbOjdpSDcHUtfYNqR3pX/8mGk4d
tGn3hN1mijvUPgcnHfv9aoh4KAti6sGMcVHgFZ4lq1ihvoRGUCOfh9tPGeZwqcrj
K+znsfsZC6sq11h4pZUZ6ZZ3QKqyCJ/xLxuR23ThnXKi3mzQG99rhnRvoxTdOPc=
=7WTq
-END PGP SIGNATURE-

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Victor Stinner
 I don't think its a bug in the applications.

swift gets its version using pkg_resources, or falls back to pbr:
https://github.com/openstack/swift/blob/master/swift/__init__.py

I mean that other applications may do something similar?

Victor

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Ryan Brown
On 04/20/2015 08:22 AM, Victor Stinner wrote:
 I believe Redhat patch it out. I don't think they should need to,
 since we have explicit knobs for distros to use.
 
 pbr pulls pip which we don't want in RHEL. Example of patches in RDO:
 
 https://github.com/redhat-openstack/nova/commit/a19939c8f9a7b84b8a4d713fe3d26949e5664089
 https://github.com/redhat-openstack/python-keystoneclient/commit/e02d529a87aef8aaca0616c8ee81de224bf1f52a
 https://github.com/redhat-openstack/neutron/commit/85302b75362df30270383e3a373e60e81b1b2384
 (well, it's always the same change)
 
 Can't we enhance pbr to build (source/wheel) distributions of applications 
 which don't depend on pbr? Basically implement these patches in pbr?
 
 I read somewhere that pkg_resources may also be used to get the version.
 

You're absolutely correct, here's a quick snippet to get the version as
a string:

import pkg_resources
pkg_resources.get_distribution('nova').version

Where, of course, s/nova/any-package-name/

-- 
Ryan Brown / Software Engineer, Openstack / Red Hat, Inc.

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Victor Stinner
 I believe Redhat patch it out. I don't think they should need to,
 since we have explicit knobs for distros to use.

pbr pulls pip which we don't want in RHEL. Example of patches in RDO:

https://github.com/redhat-openstack/nova/commit/a19939c8f9a7b84b8a4d713fe3d26949e5664089
https://github.com/redhat-openstack/python-keystoneclient/commit/e02d529a87aef8aaca0616c8ee81de224bf1f52a
https://github.com/redhat-openstack/neutron/commit/85302b75362df30270383e3a373e60e81b1b2384
(well, it's always the same change)

Can't we enhance pbr to build (source/wheel) distributions of applications 
which don't depend on pbr? Basically implement these patches in pbr?

I read somewhere that pkg_resources may also be used to get the version.

Victor

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Victor Stinner
 If there's nothing majorly wrong mid-L, I'd like to release 1.0.0 just
 to get us into 'ok its stable' mentality.

I read that many packages modify the source code of libraries and applications 
to avoid a dependency to pbr at runtime. What's the status of this issue? Is 
pbr still used/required to get the version of a package a runtime?

I'm not sure that it's an issue in pbr itself. Maybe applications should be 
fixed instead.

(Sorry if it was already discussed and I missed the conclusion.)

Victor

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Robert Collins
On 20 April 2015 at 22:10, Victor Stinner vstin...@redhat.com wrote:
 If there's nothing majorly wrong mid-L, I'd like to release 1.0.0 just
 to get us into 'ok its stable' mentality.

 I read that many packages modify the source code of libraries and 
 applications to avoid a dependency to pbr at runtime. What's the status of 
 this issue? Is pbr still used/required to get the version of a package a 
 runtime?

I believe Redhat patch it out. I don't think they should need to,
since we have explicit knobs for distros to use.

There is a raised concern about performance from the keystone CLI
thread, but I've not seen any followup to confirm that it was indeed
testing an *installed* CLI, not one running out of git.

 I'm not sure that it's an issue in pbr itself. Maybe applications should be 
 fixed instead.

I don't think its a bug in the applications.

Maybe someone from RedHat can file a bug on pbr describing what goes wrong?

-Rob


-- 
Robert Collins rbtcoll...@hp.com
Distinguished Technologist
HP Converged Cloud

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


[openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Robert Collins
So, we've fixed up the semver logic.

I went through the review backlog and merged the stuff that was good.

One thing in particular was problematic - prompting me to put up
https://review.openstack.org/#/c/174646/ - the commit this backs out
added per-platform requirements.txt files, which in light of both the
related discussions - one for environment markers, and one for
stopping using them for install_requires, seems like a bad idea to me.

We're working through the ecosystem changes needed to use environment
markers pervasively right now, which is a straight forward process, I
suspect it will take a month or so to get there, but not much longer.

So - I'd like to propose that we release 0.11 as soon as the servers
have been released and L is properly open - so that we've the whole
release to deal with any fallout.

If there's nothing majorly wrong mid-L, I'd like to release 1.0.0 just
to get us into 'ok its stable' mentality.

-Rob

-- 
Robert Collins rbtcoll...@hp.com
Distinguished Technologist
HP Converged Cloud

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [oslo][pbr] getting 0.11 out the door. Maybe even 1.0

2015-04-20 Thread Robert Collins
On 21 April 2015 at 00:22, Victor Stinner vstin...@redhat.com wrote:
 I believe Redhat patch it out. I don't think they should need to,
 since we have explicit knobs for distros to use.

 pbr pulls pip which we don't want in RHEL. Example of patches in RDO:

 https://github.com/redhat-openstack/nova/commit/a19939c8f9a7b84b8a4d713fe3d26949e5664089
 https://github.com/redhat-openstack/python-keystoneclient/commit/e02d529a87aef8aaca0616c8ee81de224bf1f52a
 https://github.com/redhat-openstack/neutron/commit/85302b75362df30270383e3a373e60e81b1b2384
 (well, it's always the same change)

 Can't we enhance pbr to build (source/wheel) distributions of applications 
 which don't depend on pbr? Basically implement these patches in pbr?

There is some fundamental misunderstanding here.

http://docs.openstack.org/developer/pbr/packagers.html

Firstly, pbr has no runtime dep on pip - it doesn't import it. So you
don't need pip installed when an installed package uses pbr to get its
version.

Secondly, there are variables - see the link above - to control or
override all the bits you could want.

Lastly, pbr will use pkg_resources.

 I read somewhere that pkg_resources may also be used to get the version.

Yes, and pbr does that, when the package is installed.

So - I still don't understand *why* RDO is patching it out.

It needs one of the RDO packagers to file a bug describing what
happens in sufficient detail that we can fix it.

-Rob

-- 
Robert Collins rbtcoll...@hp.com
Distinguished Technologist
HP Converged Cloud

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev