Alon Bar-Lev has uploaded a new change for review. Change subject: packaging: setup: database: cast port to str ......................................................................
packaging: setup: database: cast port to str old psycopg2 does not accept unicode string as port. python-psycopg2-2.0.14-2.el6.x86_64 TypeError: port must be a string or int *DO NOT* cast to int as usock will not work. Bug-Url: https://bugzilla.redhat.com/show_bug.cgi?id=1067058 Change-Id: I51476e7a07ae6bf475415329873c96ddea638686 Signed-off-by: Alon Bar-Lev <[email protected]> --- M packaging/setup/ovirt_engine_setup/database.py 1 file changed, 6 insertions(+), 1 deletion(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/90/24790/1 diff --git a/packaging/setup/ovirt_engine_setup/database.py b/packaging/setup/ovirt_engine_setup/database.py index b86de32..b1f9a14 100644 --- a/packaging/setup/ovirt_engine_setup/database.py +++ b/packaging/setup/ovirt_engine_setup/database.py @@ -145,9 +145,14 @@ database=database, ) else: + # + # port cast is required as old psycopg2 + # does not support unicode strings for port. + # do not cast to int to avoid breaking usock. + # _connection = connection = psycopg2.connect( host=host, - port=port, + port=str(port), user=user, password=password, database=database, -- To view, visit http://gerrit.ovirt.org/24790 To unsubscribe, visit http://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I51476e7a07ae6bf475415329873c96ddea638686 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: ovirt-engine-3.4 Gerrit-Owner: Alon Bar-Lev <[email protected]> _______________________________________________ Engine-patches mailing list [email protected] http://lists.ovirt.org/mailman/listinfo/engine-patches
