Public bug reported:

When setting up a development environment following the instructions
here:

http://docs.openstack.org/developer/keystone/devref/development.environment.html

On Ubuntu 16.04.1 when installing dependencies from test-
requirements.txt using pip, the installation fails when it tries to
install psycopg2:

Collecting psycopg2>=2.5; extra == "postgresql" (from 
oslo.db[fixtures,mysql,postgresql]>=4.1.0->-r test-requirements.txt (line 13))
  Downloading psycopg2-2.6.2.tar.gz (376kB)
    100% |████████████████████████████████| 378kB 769kB/s
    Complete output from command python setup.py egg_info:
    running egg_info
    creating pip-egg-info/psycopg2.egg-info
    writing pip-egg-info/psycopg2.egg-info/PKG-INFO
    writing top-level names to pip-egg-info/psycopg2.egg-info/top_level.txt
    writing dependency_links to 
pip-egg-info/psycopg2.egg-info/dependency_links.txt
    writing manifest file 'pip-egg-info/psycopg2.egg-info/SOURCES.txt'
    warning: manifest_maker: standard file '-c' not found

    Error: pg_config executable not found.

    Please add the directory containing pg_config to the PATH
    or specify the full executable path with the option:

        python setup.py build_ext --pg-config /path/to/pg_config build
...

    or with the pg_config option in 'setup.cfg'.

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in 
/tmp/pip-build-j460mO/psycopg2/


Googling this error brings you to this fix from stackoverflow:

http://stackoverflow.com/questions/11618898/pg-config-executable-not-
found

Which simply involves installing the libpq-dev package.  This fixes the
problem and the rest of test-requirements.txt are installed fine.

Recommend adding libpg-dev (Ubuntu/Debian) along with other package
managers to the list of dependencies to install before using pip:

http://docs.openstack.org/developer/keystone/devref/development.environment.html
#installing-dependencies

** Affects: keystone
     Importance: Undecided
     Assignee: Gage Hugo (gagehugo)
         Status: New


** Tags: documentation

** Changed in: keystone
     Assignee: (unassigned) => Gage Hugo (gagehugo)

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Identity (keystone).
https://bugs.launchpad.net/bugs/1608653

Title:
  Installing reqs from test-requirements.txt using pip fails due to
  missing lib package for psycopg2

Status in OpenStack Identity (keystone):
  New

Bug description:
  When setting up a development environment following the instructions
  here:

  
http://docs.openstack.org/developer/keystone/devref/development.environment.html

  On Ubuntu 16.04.1 when installing dependencies from test-
  requirements.txt using pip, the installation fails when it tries to
  install psycopg2:

  Collecting psycopg2>=2.5; extra == "postgresql" (from 
oslo.db[fixtures,mysql,postgresql]>=4.1.0->-r test-requirements.txt (line 13))
    Downloading psycopg2-2.6.2.tar.gz (376kB)
      100% |████████████████████████████████| 378kB 769kB/s
      Complete output from command python setup.py egg_info:
      running egg_info
      creating pip-egg-info/psycopg2.egg-info
      writing pip-egg-info/psycopg2.egg-info/PKG-INFO
      writing top-level names to pip-egg-info/psycopg2.egg-info/top_level.txt
      writing dependency_links to 
pip-egg-info/psycopg2.egg-info/dependency_links.txt
      writing manifest file 'pip-egg-info/psycopg2.egg-info/SOURCES.txt'
      warning: manifest_maker: standard file '-c' not found

      Error: pg_config executable not found.

      Please add the directory containing pg_config to the PATH
      or specify the full executable path with the option:

          python setup.py build_ext --pg-config /path/to/pg_config build
  ...

      or with the pg_config option in 'setup.cfg'.

      ----------------------------------------
  Command "python setup.py egg_info" failed with error code 1 in 
/tmp/pip-build-j460mO/psycopg2/

  
  Googling this error brings you to this fix from stackoverflow:

  http://stackoverflow.com/questions/11618898/pg-config-executable-not-
  found

  Which simply involves installing the libpq-dev package.  This fixes
  the problem and the rest of test-requirements.txt are installed fine.

  Recommend adding libpg-dev (Ubuntu/Debian) along with other package
  managers to the list of dependencies to install before using pip:

  
http://docs.openstack.org/developer/keystone/devref/development.environment.html
  #installing-dependencies

To manage notifications about this bug go to:
https://bugs.launchpad.net/keystone/+bug/1608653/+subscriptions

-- 
Mailing list: https://launchpad.net/~yahoo-eng-team
Post to     : yahoo-eng-team@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yahoo-eng-team
More help   : https://help.launchpad.net/ListHelp

Reply via email to