Import pymysql in lower case

PyMySQL package needs to be imported in lower case. Currenty,
all ACL applies are failing in our production instance due to
this bug.

Change-Id: Iaab56b8bc5caeba32de5db03cc87706dc6afbce9
This commit is contained in:
Yolanda Robla 2015-11-15 09:53:26 +01:00
parent df70c55bdf
commit 6414c7b80b
2 changed files with 4 additions and 4 deletions

View File

@ -26,7 +26,7 @@ import subprocess
from launchpadlib import launchpad
from launchpadlib import uris
import PyMySQL
import pymysql
from jeepyb import projects as p
@ -154,7 +154,7 @@ def main():
'Gerrit User Sync', uris.LPNET_SERVICE_ROOT, GERRIT_CACHE_DIR,
credentials_file=GERRIT_CREDENTIALS, version='devel')
conn = PyMySQL.connect(
conn = pymysql.connect(
host=DB_HOST, user=DB_USER, password=DB_PASS, db=DB_DB)
find_specs(lpconn, conn, args)

View File

@ -53,8 +53,8 @@ def connect():
DB_DB = gerrit_config.get("database", "database")
if DB_TYPE.upper() == "MYSQL":
import PyMySQL
db_connection = PyMySQL.connect(
import pymysql
db_connection = pymysql.connect(
host=DB_HOST, user=DB_USER, password=DB_PASS, db=DB_DB)
else:
import psycopg2