The 2nd get_db_session() parameter should have a default

Bug #821405 reported by Muharem Hrnjadovic
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenQuake (deprecated)
Fix Released
Low
Anton Gritsay

Bug Description

Please see: openquake/db/alchemy/db_utils.py, line 72

<mattiab> al-maisan: while reviewing https://github.com/gem/openquake/pull/373 lars noticed that there is just a oq_get4gem and there aren't reader/writer roles and hence get_db_session does not work unless a env variable is set
<mattiab> al-maisan: should I add reader/writer roles or is the single oq_ged4gem user intentional?
<al-maisan> mattiab: yeah .. we could do get_db_session("get4gem", "")
<al-maisan> I was thinking of assigning a default ("writer") to the second param
<al-maisan> sorry, the default should be: ""
<al-maisan> in which case get_db_session("get4gem") suffices
<al-maisan> what do you think?
<mattiab> LGTM

Tags: sys-quality
Changed in openquake:
status: New → Confirmed
importance: Undecided → Low
assignee: nobody → Anton Gritsay (angri)
tags: added: sys-quality
Anton Gritsay (angri)
Changed in openquake:
status: Confirmed → Fix Committed
John Tarter (toh2)
Changed in openquake:
milestone: none → 0.4.6
Changed in openquake:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.