I think building the openstack master branch will require moving the images to python3. This has implications to the base image, to how we build the base wheels tarball, and possibly to arguments passed to loci (as well as moving to a newer loci SHA). I believe Al started looking at this last week, but got pulled off to look at some other issues. From your reply, it sounds like maybe you’ve also done some of this?

 

When we explicitly add wheels to the tarball, we update the upper-constraints file to align with the module we’ve included. This would be why the build is looking for 4.7.0 here. There is an upper-constraints.txt file in the tarball itself which you can check.

 

The libvirt wheel building is python2 only, currently. So it would need to be built for python3 - if that’s possible for 4.7.0. If a newer version of libvirt-python is needed for python3 support, then it will need to be updated. I don’t know how big that effort will be.

 

 

From: Liu, ZhipengS [mailto:zhipengs.liu@intel.com]
Sent: Thursday, March 05, 2020 1:06 AM
To: Penney, Don; YuChengDe; starlingx-discuss@lists.starlingx.io
Subject: RE: [Starlingx-discuss] [OpenStack Upgrade]Failed when build StarlingX docker images

 

Hi Penney,

 

We just used OpenStack master branch and upper-constraint file below

https://raw.githubusercontent.com/openstack/requirements/master/upper-constraints.txt

libvirt-python===5.10.0;python_version=='2.7'
libvirt-python===6.0.0;python_version=='3.6'
libvirt-python===6.0.0;python_version=='3.7'

 

In nova setup.cfg. it adds python require info. python-requires = >=3.6

Then we built python3 related packages to the base image and rebuilt nova image to fix python3 issue.

 

But there is still an error below.

collecting cryptography===2.8

  Downloading cryptography-2.8-cp34-abi3-manylinux2010_x86_64.whl (2.3 MB)

ERROR: Could not find a version that satisfies the requirement libvirt-python===4.7.0 (from -c /tmp/wheels/upper-constraints.txt (line 274)) (from versions: none)

ERROR: No matching distribution found for libvirt-python===4.7.0 (from -c /tmp/wheels/upper-constraints.txt (line 274))

The command '/bin/sh -c /opt/loci/scripts/install.sh' returned a non-zero code: 1

 

From code, I saw that we already built libvirt_python-4.7.0-cp27-cp27mu-linux_x86_64.whl through a patch which
Seems related to python2.
cgcs-root/stx/integ/virt/libvirt-python/centos/meta_patches$   0002-Build-python-wheel.patch

 

It needs libvirt-python whl for python3, right?

 

Do we have plan to upgrade libvirt-python to 6.0.0?

Any comment?

 

Thanks a lot!

Zhipeng

From: Penney, Don <Don.Penney@windriver.com>
Sent: 2020
227 0:25
To: YuChengDe <yu.chengde@99cloud.net>; starlingx-discuss@lists.starlingx.io
Subject: Re: [Starlingx-discuss] Failed when build StarlingX docker images

 

I was able to successfully build stx-nova image in master with no changes. Do you have any customizations in your environment?

 

 

From: Penney, Don [mailto:Don.Penney@windriver.com]
Sent: Wednesday, February 26, 2020 10:38 AM
To: YuChengDe; starlingx-discuss@lists.starlingx.io
Subject: Re: [Starlingx-discuss] Failed when build StarlingX docker images

 

I guess the upstream nova has updated its requirements.txt to drop support for python2 completely. Al has started digging into the work required to move our image builds to python3, but it’s going to be a multi-day effort.

 

We’re checking to see if there’s a temporary workaround to get this build working in the short term.

 

 

 

From: YuChengDe [mailto:yu.chengde@99cloud.net]
Sent: Wednesday, February 26, 2020 5:42 AM
To: starlingx-discuss@lists.starlingx.io
Subject: [Starlingx-discuss] Failed when build StarlingX docker images

 

Hi: 

 I have some problem as building the StarlingX docker image. 

 When I built stx-nova through build-stx-base.sh, the process was stuck, and leave the error log as below.

 Please offer me some suggestions.

 Many thanks.

 

...

dirname /opt/loci/scripts/install.sh

/opt/loci/scripts/pip_install.sh /tmp/heat pycrypto pylint

packages='/tmp/heat pycrypto pylint'

pip install --no-cache-dir --only-binary :all: --no-compile -c /tmp/wheels/upper-constraints.txt --find-links /tmp/wheels/ /tmp/heat pycrypto pylint

DEPRECATION: Python 2.7 reached the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 is no longer maintained. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support

...

Ignoring sphinxcontrib-applehelp: markers 'python_version == "3.6"' don't match your environment

Ignoring sphinxcontrib-applehelp: markers 'python_version == "3.7"' don't match your environment

Ignoring scikit-learn: markers 'python_version == "3.6"' don't match your environment

Ignoring scikit-learn: markers 'python_version == "3.7"' don't match your environment

Looking in links: /tmp/wheels/
Processing /tmp/nova
ERROR: Package 'nova' requires a different Python: 2.7.5 not in '>=3.6'
command '/bin/sh -c /opt/loci/scripts/install.sh' returned a non-zero code: 1

 

 

Image removed by sender.

--
—————————————————————————————I 
九州云信息科技有限公司  99CLOUD Inc.

于成德   产品开发部
邮箱(Email):  yu.chengde@99cloud.net
手机(Mobile):  13816965096
地址(Addr):  上海市局门路4271号楼206
Room 206, Bldg 1, No.427 JuMen Road, ShangHai, China
网址(Site):  http://www.99cloud.net