dbapi.py
changeset 8992 55a1567d92a0
parent 8934 48a6e6b88b16
parent 8983 2a244f90a1e3
child 9016 0368b94921ed
child 9255 46f41c3e1443
child 9297 9a44436cd5a5
equal deleted inserted replaced
8989:8742f4bf029f 8992:55a1567d92a0
   211         if cnxprops and cnxprops.cnxtype == 'zmq':
   211         if cnxprops and cnxprops.cnxtype == 'zmq':
   212             database = kwargs.pop('host')
   212             database = kwargs.pop('host')
   213         elif cnxprops and cnxprops.cnxtype == 'inmemory':
   213         elif cnxprops and cnxprops.cnxtype == 'inmemory':
   214             database = 'inmemory://' + database
   214             database = 'inmemory://' + database
   215         else:
   215         else:
   216             database = 'pyro://%s/%s.%s' % (kwargs.pop('host', ''),
   216             host = kwargs.pop('host', None)
   217                                             kwargs.pop('group', 'cubicweb'),
   217             if host is None:
   218                                             database)
   218                 host = ''
       
   219             group = kwargs.pop('group', None)
       
   220             if group is None:
       
   221                 group = 'cubicweb'
       
   222             database = 'pyro://%s/%s.%s' % (host, group, database)
   219     puri = urlparse(database)
   223     puri = urlparse(database)
   220     method = puri.scheme.lower()
   224     method = puri.scheme.lower()
   221     if method == 'inmemory':
   225     if method == 'inmemory':
   222         config = cwconfig.instance_configuration(puri.path)
   226         config = cwconfig.instance_configuration(puri.path)
   223     else:
   227     else: