Error: could not determine PostgreSQL version from "10.4"
A higher version of psycopg2 fixed the issue for me, update your requirements.txt to:
...
psycopg2==2.7.5
...
Solution for me:
$wget https://files.pythonhosted.org/packages/51/2f/48c3bda0b629f6e6b2c0dc57d737f2612389d2c43797209034c604349b71/redshift-sqlalchemy-0.4.tar.gz
$ tar -zxvf redshift-sqlalchemy-0.4.tar.gz
Change inside requires.txt psycopg2==2.5 to psycopg2 (2.7.6.1)
$vi redshift-sqlalchemy-0.4/redshift_sqlalchemy.egg-info/requires.txt
.......
psycopg2==2.7.6.1 <---Change Here
SQLAlchemy>=0.8.0
.................
Change inside setup.py psycopg2
$vi redshift-sqlalchemy-0.4/setup.py
CHANGE
..........
install_requires=['psycopg2==2.5', 'SQLAlchemy>=0.8.0'],
..........
TO
..........
install_requires=['psycopg2==2.7.6.1', 'SQLAlchemy>=0.8.0'],
Run the manual pip installation
$ pip install -r redshift-sqlalchemy-0.4/redshift_sqlalchemy.egg-info/requires.txt file:///home/etl/redshift-sqlalchemy-0.4/