Should include libpcre3-dev in general prerequisite package

Bug #1745935 reported by Jianghua Wang
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
devstack
In Progress
Undecided
Jianghua Wang

Bug Description

As python-pcre is now added in the upper-constraints.txt and python-pcre depends on libpcre3-dev.
https://github.com/openstack/requirements/blob/master/upper-constraints.txt#L440

We should include libpcre3-dev as the general prerequisite package, otherwise we will get the following error :

2018-01-29 05:13:26.786 | Failed to build python-pcre
2018-01-29 05:13:26.788 | Installing collected packages: lxml, asn1crypto, ipaddress, cryptography, pyasn1, bcrypt, PyNaCl, paramiko, python-cinderclient, warlock, pyOpenSSL, python-glanceclient, numpy, websockify, retrying, os-win, os-brick, os-traits, os-vif, python-barbicanclient, castellan, microversion-parse, voluptuous, tooz, cursive, pyasn1-modules, networkx, automaton, taskflow, pypowervm, os-service-types, nova, Pillow, funcparserlib, webcolors, blockdiag, actdiag, attrs, colorama, wsgi-intercept, py, pluggy, pytest, ply, jsonpath-rw, jsonpath-rw-ext, gabbi, os-api-ref, suds-jurko, oslo.vmware, psycopg2, python-ironicclient, python-pcre, requests-mock, seqdiag, sphinxcontrib-actdiag, sphinxcontrib-seqdiag, whereto
2018-01-29 05:13:30.626 | Running setup.py develop for nova
2018-01-29 05:13:34.472 | Running setup.py install for python-pcre: started
2018-01-29 05:13:34.880 | Running setup.py install for python-pcre: finished with status 'error'
2018-01-29 05:13:34.880 | Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-eoNXII/python-pcre/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-CEkr1Z-record/install-record.txt --single-version-externally-managed --compile:
2018-01-29 05:13:34.880 | running install
2018-01-29 05:13:34.880 | running build
2018-01-29 05:13:34.880 | running build_py
2018-01-29 05:13:34.880 | creating build
2018-01-29 05:13:34.880 | creating build/lib.linux-x86_64-2.7
2018-01-29 05:13:34.880 | copying python/pcre.py -> build/lib.linux-x86_64-2.7
2018-01-29 05:13:34.880 | running build_ext
2018-01-29 05:13:34.880 | building '_pcre' extension
2018-01-29 05:13:34.880 | creating build/temp.linux-x86_64-2.7
2018-01-29 05:13:34.880 | creating build/temp.linux-x86_64-2.7/src
2018-01-29 05:13:34.880 | x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -Wdate-time -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -I/usr/include/python2.7 -c src/pcremodule.c -o build/temp.linux-x86_64-2.7/src/pcremodule.o -fno-strict-aliasing
2018-01-29 05:13:34.880 | src/pcremodule.c:32:18: fatal error: pcre.h: No such file or directory
2018-01-29 05:13:34.880 | compilation terminated.
2018-01-29 05:13:34.880 | error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
2018-01-29 05:13:34.881 |
2018-01-29 05:13:34.881 | ----------------------------------------

Revision history for this message
Jianghua Wang (wjh-fresh) wrote :

At the moment, the package of libpcre3-dev is included in devstack/files/debs/horizon as horizon's prerequisite package. So it won't impact the nodes which have horizon service enabled. In multiple nodes testing env, if some nodes don't have horizon enable e.g. compute only node, it will report the above error.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to devstack (master)

Fix proposed to branch: master
Review: https://review.openstack.org/538841

Changed in devstack:
assignee: nobody → Jianghua Wang (wjh-fresh)
status: New → In Progress
description: updated
Revision history for this message
Jianghua Wang (wjh-fresh) wrote :

When setup package for nova, it will also install the package from test-requirements.txt which has whereto (“whereto>=0.3.0 # Apache-2.0”);
2018-01-29 04:19:41.019 | +inc/python:_setup_package_with_constraints_edit:558 ^[[m^[(B /opt/stack/requirements/.venv/bin/edit-constraints /opt/stack/requirements/upper-constraints.txt -- nova '-e file:///opt/stack/nova#egg=nova'
2018-01-29 04:19:43.115 | +inc/python:pip_install:359 ^[[m^[(B sudo -H http_proxy= https_proxy= no_proxy= PIP_FIND_LINKS= SETUPTOOLS_SYS_PATH_TECHNIQUE=rewrite /usr/local/bin/pip2.7 install -c /opt/stack/requirements/upper-constraints.txt -r /opt/stack/nova/test-requirements.txt -e /opt/stack/nova

https://github.com/openstack-dev/devstack/blob/master/inc/python#L348

https://github.com/openstack/nova/blob/ec8b9a59c018c41bb18d0e712ad2868706ac9db7/test-requirements.txt#L40

And whereto requires python-pcre (http://git.openstack.org/cgit/openstack/whereto/tree/requirements.txt); but python-pcre depends on libpcre3-dev.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on devstack (master)

Change abandoned by Ian Wienand (<email address hidden>) on branch: master
Review: https://review.openstack.org/538841
Reason: Let's cover this in I59fc688519341c90dc33b79d536f0625a6c4dd17 -- it was actually first, but it also has the RPM packages. I'm going to remove this from the queue for clarity

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.