python: fix bug in negation of metaquery terms (should always use bitwise inversion, not "not" which cannot be overrided)