I am using Django 1.7 and for authentication I am using Django allauth. For sending email, I started using zoho smtp server. It is able to send normal & transactional mails but it cannot send signup conversation email. It shows the error:
SMTPDataError at /accounts/signup/
(553, b'Relaying disallowed as webmaster#localhost')
The traceback is :
69. return self.dispatch(request, *args, **kwargs)
File "C:\Python34\lib\site-packages\django\utils\decorators.py" in _wrapper
29. return bound_func(*args, **kwargs)
File "C:\Python34\lib\site-packages\django\views\decorators\debug.py" in sensitive_post_parameters_wrapper
76. return view(request, *args, **kwargs)
File "C:\Python34\lib\site-packages\django\utils\decorators.py" in bound_func
25. return func.__get__(self, type(self))(*args2, **kwargs2)
File "C:\Users\sp\industryo\allauth\account\views.py" in dispatch
167. return super(SignupView, self).dispatch(request, *args, **kwargs)
File "C:\Users\sp\industryo\allauth\account\views.py" in dispatch
62. **kwargs)
File "C:\Users\sp\industryo\allauth\account\views.py" in dispatch
145. **kwargs)
File "C:\Python34\lib\site-packages\django\views\generic\base.py" in dispatch
87. return handler(request, *args, **kwargs)
File "C:\Users\sp\industryo\allauth\account\views.py" in post
78. response = self.form_valid(form)
File "C:\Users\sp\industryo\allauth\account\views.py" in form_valid
183. self.get_success_url())
File "C:\Users\sp\industryo\allauth\account\utils.py" in complete_signup
162. signal_kwargs=signal_kwargs)
File "C:\Users\sp\industryo\allauth\account\utils.py" in perform_login
123. send_email_confirmation(request, user, signup=signup)
File "C:\Users\sp\industryo\allauth\account\utils.py" in send_email_confirmation
291. signup=signup)
File "C:\Users\sp\industryo\allauth\account\models.py" in send_confirmation
60. confirmation.send(request, signup=signup)
File "C:\Users\sp\industryo\allauth\account\models.py" in send
137. ctx)
File "C:\Users\sp\industryo\allauth\account\adapter.py" in send_mail
100. msg.send()
File "C:\Python34\lib\site-packages\django\core\mail\message.py" in send
286. return self.get_connection(fail_silently).send_messages([self])
File "C:\Python34\lib\site-packages\django\core\mail\backends\smtp.py" in send_messages
99. sent = self._send(message)
File "C:\Python34\lib\site-packages\django\core\mail\backends\smtp.py" in _send
115. self.connection.sendmail(from_email, recipients, message.as_bytes(linesep='\r\n'))
File "C:\Python34\lib\smtplib.py" in sendmail
800. raise SMTPDataError(code, resp)
Exception Type: SMTPDataError at /accounts/signup/
Exception Value: (553, b'Relaying disallowed as webmaster#localhost')
What is the issue here? How can I solve this problem?
Change DEFAULT_FROM_EMAIL in your settings. The error message is because your email provider does not accept the default value, webmaster#localhost.
Related
User can register without a profile image.
Now I get error that no file was associated with the login.
Why does it validate the form and then try to save the image?
It should not check for the image.
Traceback:
File "/usr/local/lib/python2.7/dist-packages/django/core/handlers/exception.py" in inner
41. response = get_response(request)
File "/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py" in _get_response
187. response = self.process_exception_by_middleware(e, request)
File "/usr/local/lib/python2.7/dist-packages/django/core/handlers/base.py" in _get_response
185. response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/views/generic/base.py" in view
68. return self.dispatch(request, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/utils/decorators.py" in _wrapper
67. return bound_func(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/views/decorators/debug.py" in sensitive_post_parameters_wrapper
76. return view(request, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/utils/decorators.py" in bound_func
63. return func.__get__(self, type(self))(*args2, **kwargs2)
File "/usr/local/lib/python2.7/dist-packages/django/utils/decorators.py" in _wrapper
67. return bound_func(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/utils/decorators.py" in _wrapped_view
149. response = view_func(request, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/utils/decorators.py" in bound_func
63. return func.__get__(self, type(self))(*args2, **kwargs2)
File "/usr/local/lib/python2.7/dist-packages/django/utils/decorators.py" in _wrapper
67. return bound_func(*args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/views/decorators/cache.py" in _wrapped_view_func
57. response = view_func(request, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/utils/decorators.py" in bound_func
63. return func.__get__(self, type(self))(*args2, **kwargs2)
File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/views.py" in dispatch
90. return super(LoginView, self).dispatch(request, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/views/generic/base.py" in dispatch
88. return handler(request, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/django/views/generic/edit.py" in post
183. return self.form_valid(form)
File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/views.py" in form_valid
119. auth_login(self.request, form.get_user())
File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/__init__.py" in login
161. user_logged_in.send(sender=user.__class__, request=request, user=user)
File "/usr/local/lib/python2.7/dist-packages/django/dispatch/dispatcher.py" in send
193. for receiver in self._live_receivers(sender)
File "/home/django/django_project/accounts/views.py" in got_online
115. user.profile.save()
File "/home/django/django_project/accounts/models.py" in save
116. img = Image.open(self.image.path)
File "/usr/local/lib/python2.7/dist-packages/django/db/models/fields/files.py" in path
64. self._require_file()
File "/usr/local/lib/python2.7/dist-packages/django/db/models/fields/files.py" in _require_file
46. raise ValueError("The '%s' attribute has no file associated with it." % self.field.name)
Exception Type: ValueError at /login/
Exception Value: The 'image' attribute has no file associated with it.
accounts/models.py
class UserProfile(models.Model):
image = models.ImageField(upload_to=upload_image_path,null=True,blank=True)
def save(self, *args, **kwargs):
super(UserProfile,self).save(*args, **kwargs)
if self.image != None:
img = Image.open(self.image.path)
if img.height > 300 or img.width > 300:
output_size = (300, 300)
img.thumbnail(output_size)
img.save(self.image.path)
def post_save_user_receiver(sender, instance, created, *args, **kwargs):
if created:
new_profile = UserProfile.objects.get_or_create(user=instance)
The registration works without the user having a image, but the login does not.
Thank you for any help
I solved it by adding a default image to the file field:
image = models.ImageField(upload_to=upload_image_path,default='default.jpeg')
and by changing the if statement in the save method
from:
if self.image != None:
to:
if not self.image:
According to traceback, there is a signal receiver in accounts/views.py#115, that listens for user_logged_in signal and tries to save user profile:
File "/usr/local/lib/python2.7/dist-packages/django/contrib/auth/__init__.py" in login
161. user_logged_in.send(sender=user.__class__, request=request, user=user)
...
File "/home/django/django_project/accounts/views.py" in got_online
115. user.profile.save()
And in user profile save and tries to open the profile image to thumbnail it.
Using Django 1.10 I have no problem using my custom backend to login (not a custom user just the auth) but in 1.11rc1 I get the following exception:
Request Method: POST
Request URL: http://127.0.0.1:8000/admin/login/?next=/admin/
Django Version: 1.11rc1
Exception Type: FieldError
Exception Value:
Cannot resolve keyword 'request' into field. Choices are: clientcontact, crudevent, date_joined, email, <...just more fields>
The backend:
def authenticate(self, **kwargs):
if kwargs:
username = kwargs.pop("username", None)
if username:
username_or_email = Q(username=username) | Q(email=username)
password = kwargs.pop("password", None)
try:
user = User.objects.get(username_or_email, **kwargs)
except User.DoesNotExist:
pass
else:
if user.check_password(password):
return user
else:
...
In settings.py:
AUTHENTICATION_BACKENDS = ('base_app.auth_backend.JbcBackend', 'guardian.backends.ObjectPermissionBackend',)
I haven't been able to find anything, if someone could point me in the right direction that would be great.
Here is the full Traceback:
Traceback:
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/core/handlers/exception.py" in inner
41. response = get_response(request)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/core/handlers/base.py" in _get_response
187. response = self.process_exception_by_middleware(e, request)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/channels/handler.py" in process_exception_by_middleware
237. return super(AsgiHandler, self).process_exception_by_middleware(exception, request)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/core/handlers/base.py" in _get_response
185. response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/views/decorators/cache.py" in _wrapped_view_func
57. response = view_func(request, *args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/contrib/admin/sites.py" in login
393. return LoginView.as_view(**defaults)(request)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/views/generic/base.py" in view
68. return self.dispatch(request, *args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/utils/decorators.py" in _wrapper
67. return bound_func(*args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/views/decorators/debug.py" in sensitive_post_parameters_wrapper
76. return view(request, *args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/utils/decorators.py" in bound_func
63. return func.__get__(self, type(self))(*args2, **kwargs2)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/utils/decorators.py" in _wrapper
67. return bound_func(*args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/utils/decorators.py" in _wrapped_view
149. response = view_func(request, *args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/utils/decorators.py" in bound_func
63. return func.__get__(self, type(self))(*args2, **kwargs2)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/utils/decorators.py" in _wrapper
67. return bound_func(*args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/views/decorators/cache.py" in _wrapped_view_func
57. response = view_func(request, *args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/utils/decorators.py" in bound_func
63. return func.__get__(self, type(self))(*args2, **kwargs2)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/contrib/auth/views.py" in dispatch
90. return super(LoginView, self).dispatch(request, *args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/views/generic/base.py" in dispatch
88. return handler(request, *args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/views/generic/edit.py" in post
182. if form.is_valid():
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/forms/forms.py" in is_valid
183. return self.is_bound and not self.errors
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/forms/forms.py" in errors
175. self.full_clean()
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/forms/forms.py" in full_clean
385. self._clean_form()
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/forms/forms.py" in _clean_form
412. cleaned_data = self.clean()
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/contrib/auth/forms.py" in clean
187. self.user_cache = authenticate(self.request, username=username, password=password)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/contrib/auth/__init__.py" in authenticate
100. user = backend.authenticate(*args, **credentials)
File "/home/mat/PycharmProjects/jbc_services/base_app/auth_backend.py" in authenticate
19. user = User.objects.get(username_or_email, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/manager.py" in manager_method
85. return getattr(self.get_queryset(), name)(*args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/query.py" in get
370. clone = self.filter(*args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/query.py" in filter
781. return self._filter_or_exclude(False, *args, **kwargs)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/query.py" in _filter_or_exclude
799. clone.query.add_q(Q(*args, **kwargs))
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/sql/query.py" in add_q
1260. clause, _ = self._add_q(q_object, self.used_aliases)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/sql/query.py" in _add_q
1286. allow_joins=allow_joins, split_subq=split_subq,
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/sql/query.py" in build_filter
1164. lookups, parts, reffed_expression = self.solve_lookup_type(arg)
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/sql/query.py" in solve_lookup_type
1044. _, field, _, lookup_parts = self.names_to_path(lookup_splitted, self.get_meta())
File "/home/mat/.virtualenvs/jbcarcenv/lib/python3.6/site-packages/django/db/models/sql/query.py" in names_to_path
1362. "Choices are: %s" % (name, ", ".join(available)))
Exception Type: FieldError at /admin/login/
Exception Value: Cannot resolve keyword 'request' into field. Choices are: clientcontact, crudevent, date_joined, email, first_name, groups, id, is_active, is_staff, is_superuser, last_login, last_name, logentry, logged_in_user, loginevent, password, thirdpartycontact, user_bookmarks, user_permissions, user_preferences, username, userobjectpermission
try:
user = User.objects.get(username_or_email)
# The user is found, now check if the password matches
if user.check_password(password):
return user
except User.DoesNotExist:
pass
...
I'm having this problem with this use of the get_success_url() in my CreateView class:
def get_success_url(self):
search = searchViews.getIndexInstance()
search.mainfunc(self.contentForSearch, self.discussion.pk)
return HttpResponseRedirect(reverse('discussion-detail', kwargs={'slug':self.discussion.slug}))
Here's the complete error stacktrace:
Traceback:
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response
132. response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/views/generic/base.py" in view
71. return self.dispatch(request, *args, **kwargs)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapper
34. return bound_func(*args, **kwargs)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/contrib/auth/decorators.py" in _wrapped_view
22. return view_func(request, *args, **kwargs)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/utils/decorators.py" in bound_func
30. return func.__get__(self, type(self))(*args2, **kwargs2)
File "/home/nithin/djangopro/viewanalyse/discussion/views.py" in dispatch
30. return super(LoggedInMixin, self).dispatch(*args, **kwargs)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/views/generic/base.py" in dispatch
89. return handler(request, *args, **kwargs)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/views/generic/edit.py" in post
249. return super(BaseCreateView, self).post(request, *args, **kwargs)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/views/generic/edit.py" in post
215. return self.form_valid(form)
File "/home/nithin/djangopro/viewanalyse/discussion/views.py" in form_valid
374. return super(DiscussionContentUpdateCreateView, self).form_valid(form)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/views/generic/edit.py" in form_valid
194. return super(ModelFormMixin, self).form_valid(form)
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/views/generic/edit.py" in form_valid
108. return HttpResponseRedirect(self.get_success_url())
File "/home/nithin/djangopro/djangoenv/local/lib/python2.7/site-packages/django/http/response.py" in __init__
456. raise DisallowedRedirect("Unsafe redirect to URL with protocol '%s'" % parsed.scheme)
Exception Type: DisallowedRedirect at /discussion/discussion-content-update/why-i-believe-in-reincarnation-g-hijo-2015-08-09-162236316999/
Exception Value: Unsafe redirect to URL with protocol 'content-type'
What's the cause and how can I fix this?
The get_success_url method should return a URL, not an HTTP response.
def get_success_url(self):
search = searchViews.getIndexInstance()
search.mainfunc(self.contentForSearch, self.discussion.pk)
return reverse('discussion-detail',kwargs={'slug':self.discussion.slug})
It's not clear what the first two lines are for, they don't seem to be used by the reverse() call.
I have a trouble with unicode filenames on production server. When I'm trying to save file UnicodeEncodeError exception occures. Devserver works fine.
All locales for www-data are 'en_US.UTF-8'.
Also, I wrote down in /etc/apache2/envvars
export LANG='en_US.UTF-8'
export LC_ALL='en_US.UTF-8'
it did not help.
locale.getdefaultlocale() was returning (None,None), then I add following lines to django.wsgi
os.environ['LANG']='en_US.UTF-8'
os.environ['LC_ALL']='en_US.UTF-8'
After it locale.getdefaultlocale() started to return ('en_US', 'UTF8')
I noticed that sys.getdefaultencoding() returns 'ascii' but I don't know how to fix it.
Traceback:
Traceback:
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/core/handlers/base.py" in get_response
111. response = callback(request, *callback_args, **callback_kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/contrib/admin/options.py" in wrapper
366. return self.admin_site.admin_view(view)(*args, **kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/utils/decorators.py" in _wrapped_view
91. response = view_func(request, *args, **kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/views/decorators/cache.py" in _wrapped_view_func
89. response = view_func(request, *args, **kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/contrib/admin/sites.py" in inner
196. return view(request, *args, **kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/utils/decorators.py" in _wrapper
25. return bound_func(*args, **kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/utils/decorators.py" in _wrapped_view
91. response = view_func(request, *args, **kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/utils/decorators.py" in bound_func
21. return func(self, *args2, **kwargs2)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/transaction.py" in inner
209. return func(*args, **kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/contrib/admin/options.py" in add_view
955. self.save_model(request, new_object, form, False)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django_pencil/admin.py" in save_model
52. super(PictureAdmin, self).save_model(request, obj, form, change)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/contrib/admin/options.py" in save_model
709. obj.save()
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/models/base.py" in save
463. self.save_base(using=using, force_insert=force_insert, force_update=force_update)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/models/base.py" in save_base
551. result = manager._insert([self], fields=fields, return_id=update_pk, using=using, raw=raw)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/models/manager.py" in _insert
203. return insert_query(self.model, objs, fields, **kwargs)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/models/query.py" in insert_query
1576. return query.get_compiler(using=using).execute_sql(return_id)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/models/sql/compiler.py" in execute_sql
909. for sql, params in self.as_sql():
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/models/sql/compiler.py" in as_sql
872. for obj in self.query.objs
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/models/fields/files.py" in pre_save
249. file.save(file.name, file, save=False)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django_resized/forms.py" in save
31. super(ResizedImageFieldFile, self).save(name, new_content, save)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/db/models/fields/files.py" in save
86. self.name = self.storage.save(name, content)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/core/files/storage.py" in save
44. name = self.get_available_name(name)
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/core/files/storage.py" in get_available_name
70. while self.exists(name):
File "/home/myproject/myproject.com/python/lib/python2.5/site-packages/django/core/files/storage.py" in exists
230. return os.path.exists(self.path(name))
File "/usr/lib/python2.5/posixpath.py" in exists
171. st = os.stat(path)
Exception Type: UnicodeEncodeError at /admin/django_pencil/picture/add/
Exception Value: 'ascii' codec can't encode characters in position 58-65: ordinal not in range(128)
also add to django.wsgi:
import sys
reload(sys)
sys.setdefaultencoding('utf-8')
simple sys.setdefaultencoding('utf-8') will not help, reload is important
This is python 2.x problem, not the django
Debian doesn't I believe use '/etc/apache2/envvars'. Setting these values from inside of the Python script will not work as it will not initialise some things that only occur at process startup.
You either need to set the variables in the init.d startup script for Apache if envvars not consulted, or use mod_wsgi 3.4 and use daemon mode, setting the 'lang' and 'locale' options to WSGIDaemonProcess directive.
Should 'save_as' work with inlines. I'm rather baffled by the traceback but it doesn't seem to show much involvement of my own code.
The problem seems to be the id's of inlines being set to '' when saving an add form. This is handled quite happily by when you do a normal 'add':
Traceback:
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response
111. response = callback(request, *callback_args, **callback_kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/contrib/admin/options.py" in wrapper
307. return self.admin_site.admin_view(view)(*args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapped_view
93. response = view_func(request, *args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/views/decorators/cache.py" in _wrapped_view_func
79. response = view_func(request, *args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/contrib/admin/sites.py" in inner
197. return view(request, *args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapper
28. return bound_func(*args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/utils/decorators.py" in _wrapped_view
93. response = view_func(request, *args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/utils/decorators.py" in bound_func
24. return func(self, *args2, **kwargs2)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/db/transaction.py" in inner
217. res = func(*args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/contrib/admin/options.py" in add_view
879. prefix=prefix, queryset=inline.queryset(request))
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/forms/models.py" in __init__
682. queryset=qs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/forms/models.py" in __init__
415. super(BaseModelFormSet, self).__init__(**defaults)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/forms/formsets.py" in __init__
47. self._construct_forms()
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/forms/formsets.py" in _construct_forms
108. self.forms.append(self._construct_form(i))
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/forms/models.py" in _construct_form
691. form = super(BaseInlineFormSet, self)._construct_form(i, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/forms/models.py" in _construct_form
437. connection=connections[self.get_queryset().db])
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/db/models/fields/subclassing.py" in inner
53. return func(*args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/db/models/fields/subclassing.py" in inner
53. return func(*args, **kwargs)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/db/models/fields/__init__.py" in get_db_prep_lookup
306. value = self.get_prep_lookup(lookup_type, value)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/db/models/fields/__init__.py" in get_prep_lookup
292. return self.get_prep_value(value)
File "/Users/andybaker/.virtualenvs/nmdc_test/lib/python2.7/site-packages/django/db/models/fields/__init__.py" in get_prep_value
479. return int(value)
Exception Type: ValueError at /admin/property_manager/property/add/
Exception Value: invalid literal for int() with base 10: ''
Could be related to this if you're using FileFields? https://code.djangoproject.com/ticket/14760