pylint doesn’t know of which type other is (how should it, you can compare an instance of A to everything), therefore the warning. I don’t think there is a way around disabling the warning.
You can disable the warning for only that one line with appending # pylint: disable=W0212 to that line.