Jump to content

can I close an api session?


Tom Downes

Recommended Posts

Posted

Hi

I create an ftrack api session in maya, to do something.  I happen to have debug level logging on, and I notice :

ftrack_api.event.hub.EventHub : Received packet: 2::
ftrack_api.event.hub.EventHub : Sent packet: 2:::

logging in the script editor, repeatedly every few seconds.  I know how to turn off the logging, but can I close the session and stop whatever it is from running?  I know I don't need anything to be running, my task with the api is complete.

cheers!

Posted

great, thanks Mattias, that works.  I just re-read the docs and found that I can skip subscribing to the event hub in the first place too, which suits me better in this case

 

session = ftrack_api.Session(auto_connect_event_hub=False)

 

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...