contains() got an unexpected keyword argument 'escape'

Issue #1130 resolved
Former user created an issue

Hi,

Sorry for not including a ''complete, working test case''. I tried the following code:

from sqlalchemy.sql.operators import *
from myprogram.config.model import Session
from myprogram.plugins.base.model import Organization
from myprogram.plugins.base.model.organization import Organization

q = Session.query(Organization)
q.filter(contains_op(Organization.name, 'ix'))

and the traceback was:

Traceback (most recent call last):
  File "<console>", line 1, in <module>
  File "/usr/lib/python2.5/site-packages/SQLAlchemy-0.5.0beta3-py2.5.egg/sqlalchemy/sql/operators.py", line 64, in contains_op
    return a.contains(b, escape=escape)
TypeError: contains() got an unexpected keyword argument 'escape'

I fixed it by removing the ''escape'' argument from the call.

Comments (3)

  1. Log in to comment