panoptes-python-client icon indicating copy to clipboard operation
panoptes-python-client copied to clipboard

Remove subject link to subject set. But keep the subject.

Open denys-potapov opened this issue 5 years ago • 3 comments

I try to move the subject from one subject set to another. Finding and adding the subject to new subject set works:

origin = SubjectSet.find(origin_id)
destination = SubjectSet.find(destination_id)
subject = Subject.find(subject_id)
destination.add(subject)

Now I see subject in both subject sets. But when i try to unlink the subject from origin. It deletes subject, so it's not visible in both subject_sets:

# this deletes subject
origin.remove(subject)

As i understand, removeng link from subject set to subject should not remove the subject itself?

denys-potapov avatar Jul 27 '19 15:07 denys-potapov