requirements.txt should not list psycopg2

Bug #1469104 reported by Albert White
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Rally
Invalid
Medium
Luz Cazares

Bug Description

requirements.txt currently lists psycopg2 and so we attempt to install it when install_rally.sh is ran.

Postgres however is not a requirement to run rally as a user may choose mysql or sqlite, and if the user does not have postgres installed this will fail ("Error: pg_config executable not found.") and abort the install.

install_rally.sh already takes a database parameter and will pip install psycopg2 if postgres was selected. However this does not appear to try and install it in the virtualenv that may be created.

Since install_rally.sh is the documented way to install rally I suggest resolving this by:
- remove the psycopg2 line from requirements.txt
- have install_db_connector in install_rally.sh append psycopg2 to requirements.txt if postgres was selected.

Changed in rally:
status: New → Confirmed
importance: Undecided → Medium
Revision history for this message
Albert White (albertw) wrote :

Adding in from irc discussion on this one

andreykurilin albertw1: about https://bugs.launchpad.net/rally/+bug/1469104 . At first, install_rally.sh should install postgres, mysql related packages based on DBTYPE variable and than, we will be able to remove psycopg from our requirements

andreykurilin albertw1, also, I suggest to have new file: db-requirements.txt with list of all db-related stuff, so users will be able to find additional requirement for installation rally without installation script

albertw1 thanks andreykurilin . install_rally already does the pip install, but for linux distros it just tries to install the db packages also, that should probably be dependent on $DBTYPE. Should anything else depend on or source the proposed db-requirements.txt file or would it just be there to help users?

andreykurilin albertw1: db-requirements should used only for helping users to find required python package. Maybe, the better way to store such information is https://github.com/openstack/rally/blob/master/doc/source/tutorial/step_0_installation.rst

albertw1 great. Thanks for the help

Changed in rally:
assignee: nobody → Luz Cazares (luz-cazares)
Revision history for this message
Boris Pavlovic (boris-42) wrote :
Changed in rally:
status: Confirmed → Won't Fix
status: Won't Fix → Invalid
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.