Given the current behavior the same query will work or raise on error based on context.That is pretty confusing.
pgsql-bugs by date:
Соглашаюсь с условиями обработки персональных данных