Removing a component from a Note
2 2

2 posts in this topic

Removing a 'Note_Component'

Removing the component itself works fine.
I query the component by id to get the existing_component ;

server_location = session.query('Location where name is "ftrack.server"').one()
existing_component = session.query('Component where id is {0}'.format(COMPONENT_ID)).one()

server_location.remove_component(existing_component)
session.commit()

#must close after remove !
session.close()

 

but it seems like some data still remains in the Note_Component (a Note_Component without a Component ?)

Untitled.jpg.4ead5bb60cd8733379d15512987d7280.jpg

 

Do I need to clean this up by hand or is there a more straightforward method?
If by hand, how?

 

 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
2 2