-
Notifications
You must be signed in to change notification settings - Fork 38
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
DocumentAdmin: 'StringField' object has no attribute 'document_type' #4
Comments
Could you post the document that produces the error? My guess is that there is an error in the first |
I'm getting a similar error, except mine days "NoneType' object has no attribute 'document_type'". Perhaps bad data is causing this. My fix was to change the if statement at line 346:
|
Could you give me the definition of the document that causes this error? Because I don't see how and why an |
What's the easiest way to view a the contents of a document? Printing just tells me what class it is. |
|
|
Thanks for the data. Sadly it helps little without the schema. My attempts at recreating the error have so far failed miserably. |
|
I found more documents that cause the problem:
Are these documents that the admin module uses? |
@justincy Mongoadmin does not have any documents. Your data appears to be the admin object itself. I've added your fix in the last commit, so that should close that. |
I was getting the error "'StringField' object has no attribute 'document_type'"
Commenting out lines 341-361 of options.py resulted in getting the admin to work (although probably not the best thing to do, I'm guessing).
The text was updated successfully, but these errors were encountered: