From 1c2358671db99839be4e7370ab87fffda960c6e6 Mon Sep 17 00:00:00 2001 From: Andrew Willimott Date: Wed, 14 Jan 2015 14:28:43 +1300 Subject: [PATCH 1/2] Initial simple change for adding geospatial support to Teradata adaptor. --- gluon/dal/adapters/teradata.py | 1 + 1 file changed, 1 insertion(+) diff --git a/gluon/dal/adapters/teradata.py b/gluon/dal/adapters/teradata.py index f8b8f9e7..817af60b 100644 --- a/gluon/dal/adapters/teradata.py +++ b/gluon/dal/adapters/teradata.py @@ -31,6 +31,7 @@ class TeradataAdapter(BaseAdapter): 'list:integer': 'VARCHAR(4000)', 'list:string': 'VARCHAR(4000)', 'list:reference': 'VARCHAR(4000)', + 'geometry': 'ST_GEOMETRY', # http://www.info.teradata.com/HTMLPubs/DB_TTU_14_00/index.html#page/Database_Management/B035_1094_111A/ch14.055.160.html 'big-id': 'BIGINT GENERATED ALWAYS AS IDENTITY', # Teradata Specific 'big-reference': 'BIGINT', 'reference FK': ' REFERENCES %(foreign_key)s', From aaf1dd614acde834d5afa1f6d8651960a758ec45 Mon Sep 17 00:00:00 2001 From: Radu Ioan Fericean Date: Wed, 14 Jan 2015 14:16:42 +0200 Subject: [PATCH 2/2] fix issuer comparison the issuer looks like gmail.login.persona.org and the expected value was login.persona.org --- gluon/contrib/login_methods/browserid_account.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gluon/contrib/login_methods/browserid_account.py b/gluon/contrib/login_methods/browserid_account.py index 8214276f..5698f746 100644 --- a/gluon/contrib/login_methods/browserid_account.py +++ b/gluon/contrib/login_methods/browserid_account.py @@ -73,7 +73,7 @@ class BrowserID(object): auth_info_json = fetch(self.verify_url, data=verify_data) j = json.loads(auth_info_json) epoch_time = int(time.time() * 1000) # we need 13 digit epoch time - if j["status"] == "okay" and j["audience"] == audience and j['issuer'] == issuer and j['expires'] >= epoch_time: + if j["status"] == "okay" and j["audience"] == audience and j['issuer'].endswith(issuer) and j['expires'] >= epoch_time: return dict(email=j['email']) elif self.on_login_failure: #print "status: ", j["status"]=="okay", j["status"]