Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error occured when define exclude = ['name1','name2'] #15

Open
zhijiasun opened this issue Jul 8, 2014 · 2 comments
Open

error occured when define exclude = ['name1','name2'] #15

zhijiasun opened this issue Jul 8, 2014 · 2 comments

Comments

@zhijiasun
Copy link

as i understand the exclude should be a list. but when i define the exclude = ['name1','name2'], error occurs as follows:
append() takes exactly one argument (2 given)
Exception Location: ...../lib/python2.7/site-packages/adaptor/model.py in get_exclusion_fields, line 312
i think the code should be changed to :
if hasattr(cls, "Meta") and hasattr(cls.Meta, "exclude"):
list_exclusion.extend(cls.Meta.exclude)

@martinszy
Copy link

Oops, I just run in to this again... is the app not maintained now?

@jm9e
Copy link

jm9e commented Oct 1, 2020

Just ran into the same problem.

The problem is this line:

list_exclusion.append(*cls.Meta.exclude)

which should be

list_exclusion.extend(cls.Meta.exclude)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants