Hello everyone!
I encountered an issue when I install tk-core via pip, that I cannot bootstrap an SGTK instance via the toolkit manager.
I am running this code:
import tank
sa = tank.authentication.ShotgunAuthenticator()
user = sa.create_script_user(api_script='SOME-USER',
api_key='SOME-KEY',
host='https://SOME-SITE.shotgunstudio.com')
mgr = tank.bootstrap.ToolkitManager(sg_user=user)
mgr.pipeline_configuration = "Primary"
mgr.do_shotgun_config_lookup = True
mgr.plugin_id = "basic.*"
engine = mgr.bootstrap_engine("tk-shell", entity={'type': 'Project', 'id': 123})
and get this error:
File "[...]\test_sgtk.py", line 31, in setUpClass
engine = mgr.bootstrap_engine("tk-shell", entity={'type': 'Project', 'id': 123})
File "[...]\lib\site-packages\tank\bootstrap\manager.py", line 490, in bootstrap_engine
tk = self._bootstrap_sgtk(engine_name, entity)
File "[...]\lib\site-packages\tank\bootstrap\manager.py", line 1098, in _bootstrap_sgtk
config = self._get_updated_configuration(entity, progress_callback)
File "[...]\lib\site-packages\tank\bootstrap\manager.py", line 1055, in _get_updated_configuration
config.update_configuration()
File "[...]\lib\site-packages\tank\bootstrap\cached_configuration.py", line 356, in update_configuration
raise TankBootstrapError(tank.bootstrap.errors.TankBootstrapError: Configuration could not be installed: Cannot execute hook '[...]\lib\hooks\bootstrap.py' - this file does not exist on disk!.
It’d be great if that would work so, because then I could run my tests in a virtual environment. Does anybody know how to fix this?
Cheers,
Fabian