ftrack_connect_pipeline.host¶
- ftrack_connect_pipeline.host.provide_host_information(context_id, host_id, definitions, host_name, event)[source]¶
Returns dictionary with host id, host name, context id and definition from the given host_id, definitions and host_name.
host_id : Host id
definitions : Dictionary with a valid definitions
host_name : Host name
- class ftrack_connect_pipeline.host.Host(event_manager)[source]¶
Bases:
object- host_types = ['python']¶
Compatible Host types for this HOST.
- engines = {'asset_manager': <class 'ftrack_connect_pipeline.host.engine.asset_manager.AssetManagerEngine'>, 'loader': <class 'ftrack_connect_pipeline.host.engine.load.LoaderEngine'>, 'opener': <class 'ftrack_connect_pipeline.host.engine.open.OpenerEngine'>, 'publisher': <class 'ftrack_connect_pipeline.host.engine.publish.PublisherEngine'>}¶
Available engines for this host.
- property context_id¶
Return the the default context id set at host launch
- property host_id¶
Returns the current host id.
- property host_name¶
Returns the current host name
- property session¶
Returns instance of
ftrack_api.session.Session
- __init__(event_manager)[source]¶
Initialise Host with instance of
EventManager
- run(event)[source]¶
Runs the data with the defined engine type of the givent event
Returns result of the engine run.
event : Published from the client host connection at
run()
- on_register_definition(event)[source]¶
Callback of the
register()Validates the given event and subscribes to theftrack_api.event.base.Eventevents with the topicsPIPELINE_DISCOVER_HOSTandPIPELINE_HOST_RUNevent : Should be a validated and complete definitions, schema and packages dictionary coming from
ftrack_connect_pipeline_definition.resource.definitions.register.register_definitions()
- validate(data)[source]¶
Validates the given data against the correspondant plugin validator. Returns a validated data.
data : Should be a validated and complete definitions and schemas coming from
ftrack_connect_pipeline_definition.resource.definitions.register.register_definitions()
- register()[source]¶
Publishes the
ftrack_api.event.base.Eventwith the topicPIPELINE_REGISTER_TOPICwith the first host_type in the listhost_typesand type definition as the data.Callback of the event points to
on_register_definition()
- ftrack_connect_pipeline.host.engine
getEngine()BaseEngineBaseEngine.engine_typeBaseEngine.FtrackObjectManagerBaseEngine.FtrackObjectManager.DccObjectBaseEngine.FtrackObjectManager.DccObject.__init__()BaseEngine.FtrackObjectManager.DccObject.connect_objects()BaseEngine.FtrackObjectManager.DccObject.create()BaseEngine.FtrackObjectManager.DccObject.dictionary_from_object()BaseEngine.FtrackObjectManager.DccObject.from_asset_info_id()BaseEngine.FtrackObjectManager.DccObject.ftrack_plugin_idBaseEngine.FtrackObjectManager.DccObject.get()BaseEngine.FtrackObjectManager.DccObject.nameBaseEngine.FtrackObjectManager.DccObject.objects_loadedBaseEngine.FtrackObjectManager.DccObject.setdefault()BaseEngine.FtrackObjectManager.DccObject.update()
BaseEngine.FtrackObjectManager.__init__()BaseEngine.FtrackObjectManager.asset_infoBaseEngine.FtrackObjectManager.connect_objects()BaseEngine.FtrackObjectManager.create_new_dcc_object()BaseEngine.FtrackObjectManager.dcc_objectBaseEngine.FtrackObjectManager.event_managerBaseEngine.FtrackObjectManager.is_syncBaseEngine.FtrackObjectManager.objects_loadedBaseEngine.FtrackObjectManager.session
BaseEngine.DccObjectBaseEngine.DccObject.__init__()BaseEngine.DccObject.connect_objects()BaseEngine.DccObject.create()BaseEngine.DccObject.dictionary_from_object()BaseEngine.DccObject.from_asset_info_id()BaseEngine.DccObject.ftrack_plugin_idBaseEngine.DccObject.get()BaseEngine.DccObject.nameBaseEngine.DccObject.objects_loadedBaseEngine.DccObject.setdefault()BaseEngine.DccObject.update()
BaseEngine.ftrack_object_managerBaseEngine.dcc_objectBaseEngine.asset_infoBaseEngine.host_idBaseEngine.host_typesBaseEngine.__init__()BaseEngine.run_event()BaseEngine.run()BaseEngine.run_stage()BaseEngine.run_step()BaseEngine.run_definition()
- ftrack_connect_pipeline.host.engine.asset_manager
AssetManagerEngineAssetManagerEngine.engine_typeAssetManagerEngine.__init__()AssetManagerEngine.discover_assets()AssetManagerEngine.resolve_dependencies()AssetManagerEngine.select_assets()AssetManagerEngine.select_asset()AssetManagerEngine.update_assets()AssetManagerEngine.update_asset()AssetManagerEngine.load_assets()AssetManagerEngine.load_asset()AssetManagerEngine.change_version()AssetManagerEngine.unload_assets()AssetManagerEngine.unload_asset()AssetManagerEngine.remove_assets()AssetManagerEngine.remove_asset()AssetManagerEngine.run()
- ftrack_connect_pipeline.host.engine.open
- ftrack_connect_pipeline.host.engine.load
- ftrack_connect_pipeline.host.engine.publish
ftrack_connect_pipeline.host.validation¶
- ftrack_connect_pipeline.host.validation.get_schema(definition_type, schemas)[source]¶
Returns the schema in the given schemas for the given definition_type
definition_type : Type of the definition. (asset_manager, publisher…)
schemas : List of schemas.
- ftrack_connect_pipeline.host.validation.validate_schema(schemas, definition)[source]¶
Validates the schema of the given definition from the given schemas using the _validate_jsonschema function of the jsonschema.validate library.
schemas : List of schemas.
definition : Definition to be validated against the schema.
- class ftrack_connect_pipeline.host.validation.PluginDiscoverValidation(session, host_types)[source]¶
Bases:
objectPlugin discover validation base class
- __init__(session, host_types)[source]¶
Initialise PluginDiscoverValidation with instance of
ftrack_api.session.Sessionand host_types.host_types : List of compatible host types. (maya, python, nuke….)
- validate_plugins(definitions, schema_type)[source]¶
Validates all the definitions in the given definitions definitions calling the
validate_context_plugins(),validate_components_plugins(),vaildate_finalizers_plugins().Returns the invalid definition indices.
definitions : List of definitions (opener, loader, publisher and so on).
- vaildate_definition_plugins(steps, definition_name, schema_type)[source]¶
Validates plugins in the given steps running the
_discover_plugin()steps : List of dictionaries with steps, stages and plugins.
definition_name : Name of the current definition.
schema_type : Schema type of the current definition.