JasperVanDenBosch / niprov

provenance for neuroimaging data
BSD 3-Clause "New" or "Revised" License
9 stars 0 forks source link

Mongodb OperationFailure: ns name too long, max size is 128 #149

Closed JasperVanDenBosch closed 8 years ago

JasperVanDenBosch commented 8 years ago
  File "/home/jasperb/Projects/niprov/niprov/mongo.py", line 160, in search
    self.db.provenance.create_index(indexspec)
  File "/home/jasperb/Projects/niprov/env/local/lib/python2.7/site-packages/pymongo/collection.py", line 1163, in create_index
    self.__create_index(keys, kwargs)
  File "/home/jasperb/Projects/niprov/env/local/lib/python2.7/site-packages/pymongo/collection.py", line 1085, in __create_index
    sock_info, index, True, False, False, wcn)
  File "/home/jasperb/Projects/niprov/env/local/lib/python2.7/site-packages/pymongo/collection.py", line 436, in _insert
    self.codec_options, sock_info)
  File "/home/jasperb/Projects/niprov/env/local/lib/python2.7/site-packages/pymongo/pool.py", line 237, in legacy_write
    return helpers._check_gle_response(response)
  File "/home/jasperb/Projects/niprov/env/local/lib/python2.7/site-packages/pymongo/helpers.py", line 228, in _check_gle_response
    raise OperationFailure(details["err"], code, result)
OperationFailure: ns name too long, max size is 128
JasperVanDenBosch commented 8 years ago

Solution: name arg to createIndex