When comparing the Python test results it seems like the testing algorithm is comparing lists instead of sets.
For Example:
The expected output for search_triplets([-3, 0, 1, 2, -1, 1, -2]:
[-3, 1, 2][-2, 0, 2][-2, 1, 1][-1, 0, 1]
The output produced:
[[-3, 1, 2], [-2, 1, 1], [-1, 1, 0], [-2, 2, 0]] is marked as incorrect, even though technically it should be correct.