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

NameError: name 'forms' is not defined #8

Open
taryep opened this issue Nov 6, 2018 · 1 comment
Open

NameError: name 'forms' is not defined #8

taryep opened this issue Nov 6, 2018 · 1 comment

Comments

@taryep
Copy link

taryep commented Nov 6, 2018

Hello, thank you for this project that helped me a lot,
I'm using Django 1.11, I recently tried to use a molecule MolField in a django model and I got this error :
File "/opt/anaconda/lib/python3.6/site-packages/django_rdkit/models/fields.py", line 89, in formfield defaults = {'form_class': forms.CharField, 'strip': False, 'widget':forms.Textarea} NameError: name 'forms' is not defined

I corrected it by importing forms at the beggining of the file django_rdkit/models/fields.py :
from django import forms

Should it be corrected in the git repository ?

@taryep taryep changed the title django_rdkit/models/fields.py should import forms NameError: name 'forms' is not defined Nov 6, 2018
@rvianello
Copy link
Contributor

rvianello commented Nov 6, 2018 via email

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

2 participants