-
Notifications
You must be signed in to change notification settings - Fork 13
Open
Description
Hi Nathan,
Try to do I first run on this ORM
import modules.sgorm as sgorm
URL = 'https://aaa.shotgunstudio.com'
SCRIPT = 'util'
KEY = 'cf1e303123ca444c73ae421389f596410f23390423423a21d6213234234daf'
sg = sgorm.SgConnection(URL, SCRIPT, KEY)
searchResult = sg.findOne('Project', [['id', 'is', 435]])Getting this error:
Traceback (most recent call last):
File "sgorm_test.py", line 9, in <module>
searchResult = sg.findOne('Project', [['id', 'is', 435]])
File "/Users/kif/Desktop/sg_orm/modules/sgorm/ShotgunORM/SgConnection.py", line 1359, in findOne
retired_only=retired_only
File "/Users/kif/Desktop/sg_orm/modules/sgorm/ShotgunORM/SgConnection.py", line 1235, in find
newResult.append(self._createEntity(entity_type, i))
File "/Users/kif/Desktop/sg_orm/modules/sgorm/ShotgunORM/SgConnection.py", line 526, in _createEntity
result = factory.createEntity(self, sgEntityType, sgData)
File "/Users/kif/Desktop/sg_orm/modules/sgorm/ShotgunORM/SgEntityClassFactory.py", line 162, in createEntity
raise RuntimeError('unknown Entity type "%s"' % sgEntityType)
RuntimeError: unknown Entity type "Project"
I see that the _classCache gets populated inside of build function but I can not quite understand where this function runs because it is not in the init.
newClassCache[entityTypeName] = newEntityClass
if entityInfo.isCustom():
self._classCache[entityTypeLabel] = newEntityClass
Kirill
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels