-2

I am trying to run openstack unit tests, and i'm having trouble with tox
i've been following this tutorial
i have started with a brand new Ubuntu16.04 LTS instance which has python 2.7 and python 3.5
i took the exact same instructions as the tutorial, the only difference is that i clone the nova repository instead of zun : git clone https://github.com/openstack/nova

and i keep getting this error :

ERROR: invocation failed (exit code 1), logfile: /home/mnm13/nova/.tox/py35/log/py35-1.log
ERROR: actionid: py35 
msg: getenv cmdargs: ['/home/mnm13/nova/.tox/py35/bin/pip', 'install', 
    '-chttps://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt',
    '-r/home/mnm13/nova/test-requirements.txt']

you can find the log file here
Any one had this before?
thank you.

Mheni
  • 228
  • 4
  • 15
  • You should go [here](https://ask.openstack.org/en/help/) for OpenStack help. You might find something related to this there. – idjaw Feb 13 '18 at 03:10
  • thank you i posted the question over there too, but i think this i more related to python and tox – Mheni Feb 13 '18 at 03:23
  • What is in the logfile `/home/mnm13/nova/.tox/py35/log/py35-1.log`? – phd Feb 13 '18 at 11:32
  • Activate the virtual env: `source /home/mnm13/nova/.tox/py35/bin/activate` and try the command `/home/mnm13/nova/.tox/py35/bin/pip install -chttps://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt -r/home/mnm13/nova/test-requirements.txt`. What is the error? [edit] the question and add the details. – phd Feb 13 '18 at 11:33
  • @phd thank you for your reply, i have tried to run the `pip install` command in the virtual environment but it didn't work. also i have uploaded the log-file to a github [repo] (https://github.com/MheniMerz/tmp-logfile/blob/master/py35-1.log) – Mheni Feb 13 '18 at 16:27

1 Answers1

0
Building wheels for collected packages: python-pcre
…
 src/pcremodule.c:32:18: fatal error: pcre.h: No such file or directory

The error is quite obvious: to compile python-pcre you need sources for pcre library. python-pcre is just a Python wrapper for pcre which is written in C.

phd
  • 82,685
  • 13
  • 120
  • 165
  • i had to install pcre `sudo apt-get install libpcre3` `sudo apt-get install libpcre3-dev` thank you this solved the problem. i would up-vote the answer if i had enough reputation points :) – Mheni Feb 13 '18 at 17:58