SqlAlchemy. TypeError: filter_by() takes exactly 1 argument (2 given)
问题 I upgraded sqlalchemy from 0.7 to 0.9.6. After upgrade I am getting the following error: TypeError TypeError: filter_by() takes exactly 1 argument (2 given) howerver before it was working without any issue. How can I manage that issue? 回答1: Without seeing code, obviously you are calling filter_by wrong. filter_by takes only the implicit self (the 'exactly 1 argument' meaning exactly 1 positional argument) and optional keyword arguments. You are providing filter_by another positional argument,