add psycopg2 as dependency

This commit is contained in:
Jens Langhammer 2019-02-21 16:30:56 +01:00
parent 183308e444
commit b7ac4f1dd2
3 changed files with 1 additions and 7 deletions

View file

@ -4,14 +4,11 @@ import logging
import os import os
import celery import celery
# import pymysql
from django.conf import settings from django.conf import settings
# from raven import Client # from raven import Client
# from raven.contrib.celery import register_logger_signal, register_signal # from raven.contrib.celery import register_logger_signal, register_signal
# pymysql.install_as_MySQLdb()
# set the default Django settings module for the 'celery' program. # set the default Django settings module for the 'celery' program.
os.environ.setdefault("DJANGO_SETTINGS_MODULE", "passbook.core.settings") os.environ.setdefault("DJANGO_SETTINGS_MODULE", "passbook.core.settings")

View file

@ -7,6 +7,6 @@ markdown
colorlog colorlog
celery celery
redis<3.0 redis<3.0
pymysql psycopg2
idna<2.8,>=2.5 idna<2.8,>=2.5
cherrypy cherrypy

View file

@ -129,9 +129,6 @@ WSGI_APPLICATION = 'passbook.core.wsgi.application'
DATABASES = {} DATABASES = {}
for db_alias, db_config in CONFIG.get('databases').items(): for db_alias, db_config in CONFIG.get('databases').items():
if 'mysql' in db_config.get('engine'):
import pymysql
pymysql.install_as_MySQLdb()
DATABASES[db_alias] = { DATABASES[db_alias] = {
'ENGINE': db_config.get('engine'), 'ENGINE': db_config.get('engine'),
'HOST': db_config.get('host'), 'HOST': db_config.get('host'),