◄ ► | Edit | Home | Admin | en de fr et | Sign in

#1541 (TypeError at /comments/RecentComments cannot serialize on bugs.saffre-rumma)

by tonis · in Developers

Summary

 

Internal Server Error: /comments/RecentComments

TypeError at /comments/RecentComments
cannot serialize <cyfunction Comment at 0x7fe390326290> (type cython_function_or_method)

Request Method: GET
Request URL: bugs.saffre-rumma.net/comments/RecentComments?ul=de&;limit=15&start=195
Django Version: 1.9.12
Python Executable: /usr/bin/python
Python Version: 2.7.9
Python Path: ['/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages', '/usr/local/python/lino_sites/jane/env/repositories/lino', '/usr/local/python/lino_sites/jane/env/repositories/xl', '/usr/local/python/lino_sites/jane/env/repositories/noi', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk', '/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages', '/usr/lib/pymodules/python2.7', '/usr/local/python', '/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/odf', '/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/odf', '/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/odf', '/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/odf', '/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/odf', '/usr/local/python/lino_sites/bugs/env/local/lib/p
 ython2.7/site-packages/odf', '/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/odf']
Server time: Do, 2 Mär 2017 08:17:44 +0200
Installed Applications:
(u'lino.modlib.lino_startup',
 u'django.contrib.staticfiles',
 u'lino.modlib.about',
 u'lino.modlib.ipdict',
 u'lino.modlib.jinja',
 u'lino.modlib.bootstrap3',
 u'lino.modlib.printing',
 u'lino.modlib.system',
 u'django.contrib.contenttypes',
 u'lino.modlib.gfks',
 u'lino.modlib.office',
 u'lino_xl.lib.xl',
 u'lino_xl.lib.countries',
 u'lino_noi.lib.contacts',
 u'lino_noi.lib.users',
 u'lino_noi.lib.topics',
 u'lino_noi.lib.votes',
 u'lino_xl.lib.excerpts',
 u'lino.modlib.comments',
 u'lino.modlib.changes',
 u'lino_noi.lib.noi',
 u'lino_noi.projects.team.lib.tickets',
 u'lino_noi.lib.faculties',
 u'lino_noi.lib.deploy',
 u'lino_noi.projects.team.lib.clocking',
 u'lino_xl.lib.lists',
 u'lino_xl.lib.blogs',
 u'lino.modlib.notify',
 u'lino.modlib.uploads',
 u'lino.modlib.export_excel',
 u'lino.modlib.tinymce',
 u'lino.modlib.smtpd',
 u'lino.modlib.weasyprint',
 u'lino_xl.lib.appypod',
 u'lino.modlib.dashboard',
 u'rest_framework',
 u'lino.modlib.restful')
Installed Middleware:
(u'django.middleware.common.CommonMiddleware',
 u'django.middleware.locale.LocaleMiddleware',
 u'lino.core.auth.NoUserMiddleware',
 u'lino.utils.ajax.AjaxExceptionResponse')


Traceback:  

File "/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response
  149.                     response = self.process_exception_by_middleware(e, request)

File "/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/django/core/handlers/base.py" in get_response
  147.                     response = wrapped_callback(request, *callback_args, **callback_kwargs)

File "/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/django/views/generic/base.py" in view
  68.             return self.dispatch(request, *args, **kwargs)

File "/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/django/views/generic/base.py" in dispatch
  88.         return handler(request, *args, **kwargs)

File "/usr/local/python/lino_sites/jane/env/repositories/lino/lino/modlib/bootstrap3/views.py" in get
  183.         return http_response(ar, ar.actor.list_html_template, context)

File "/usr/local/python/lino_sites/jane/env/repositories/lino/lino/modlib/bootstrap3/views.py" in http_response
  61.         template.render(**context),

File "/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/jinja2/environment.py" in render
  1008.         return self.environment.handle_exception(exc_info, True)

File "/usr/local/python/lino_sites/bugs/env/local/lib/python2.7/site-packages/jinja2/environment.py" in handle_exception
  780.         reraise(exc_type, exc_value, tb)

File "/usr/local/python/lino_sites/jane/env/repositories/lino/lino/modlib/bootstrap3/config/bootstrap3/table.html" in top-level template code
  2. {% set active_page = "" %}

File "/usr/local/python/lino_sites/jane/env/repositories/lino/lino/modlib/bootstrap3/config/bootstrap3/base.html" in top-level template code
  66.     {% block main %}

File "/usr/local/python/lino_sites/jane/env/repositories/lino/lino/modlib/bootstrap3/config/bootstrap3/table.html" in block "main"
  8.     {{E.tostring(main)}}

File "/usr/local/python/lino_sites/jane/env/repositories/lino/lino/utils/xmlgen/html.py" in tostring
  132.             return super(HtmlNamespace, self).tostring(v, *args, **kw)

File "/usr/local/python/lino_sites/jane/env/repositories/lino/lino/utils/xmlgen/__init__.py" in tostring
  186.         etree.ElementTree(element).write(file, *args, **kw)

File "/usr/lib/python2.7/xml/etree/ElementTree.py" in write
  817.                 self._root, encoding, default_namespace

File "/usr/lib/python2.7/xml/etree/ElementTree.py" in _namespaces
  886.             _raise_serialization_error(tag)

File "/usr/lib/python2.7/xml/etree/ElementTree.py" in _raise_serialization_error
  1052.         "cannot serialize %r (type %s)" % (text, type(text).__name__)

Exception Type: TypeError at /comments/RecentComments
Exception Value: cannot serialize <cyfunction Comment at 0x7fe390326290> (type cython_function_or_method)
Request information:
GET:
ul = u'de'
limit = u'15'
start = u'195'

POST: No POST data

FILES: No FILES data

COOKIES: No cookie data

META:
mod_wsgi.listener_port = '80'
CONTEXT_DOCUMENT_ROOT = '/var/www/html'
SERVER_SOFTWARE = 'Apache/2.4.10 (Debian)'
SCRIPT_NAME = u''
mod_wsgi.enable_sendfile = '0'
mod_wsgi.handler_script = ''
SERVER_SIGNATURE = '<address>Apache/2.4.10 (Debian) Server at bugs.saffre-rumma.net Port 80</address>\n'
REQUEST_METHOD = 'GET'
PATH_INFO = u'/comments/RecentComments'
HTTP_FROM = 'googlebot(at)googlebot.com'
SERVER_PROTOCOL = 'HTTP/1.1'
QUERY_STRING = 'ul=de&limit=15&start=195'
HTTP_USER_AGENT = 'Mozilla/5.0 (compatible; Googlebot/2.1; +www.google.com/bot.html)'
HTTP_CONNECTION = 'Keep-alive'
SERVER_NAME = 'bugs.saffre-rumma.net'
REMOTE_ADDR = '66.249.69.236'
mod_wsgi.queue_start = '1488435464391130'
mod_wsgi.request_handler = 'wsgi-script'
apache.version = 
wsgi.url_scheme = 'http'
PATH_TRANSLATED = '/usr/local/python/lino_sites/bugs/apache/wsgi.py/comments/RecentComments'
SERVER_PORT = '80'
wsgi.multiprocess = False
mod_wsgi.input_chunked = '0'
SERVER_ADDR = '167.114.252.122'
DOCUMENT_ROOT = '/var/www/html'
mod_wsgi.process_group = 'bugs'
mod_wsgi.daemon_connects = '1'
SCRIPT_FILENAME = '/usr/local/python/lino_sites/bugs/apache/wsgi.py'
SERVER_ADMIN = 'webmaster@saffre-rumma.net'
wsgi.input = <mod_wsgi.Input object at 0x7fe377b8c3f0>
HTTP_HOST = 'bugs.saffre-rumma.net'
CONTEXT_PREFIX = ''
wsgi.multithread = True
mod_wsgi.callable_object = 'application'
mod_wsgi.daemon_restarts = '0'
REQUEST_URI = '/comments/RecentComments?ul=de&limit=15&start=195'
HTTP_ACCEPT = 'text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8'
wsgi.file_wrapper = ''
wsgi.version = 
GATEWAY_INTERFACE = 'CGI/1.1'
wsgi.run_once = False
wsgi.errors = <mod_wsgi.Log object at 0x7fe3777ba5d0>
REMOTE_PORT = '39528'
mod_wsgi.listener_host = ''
REQUEST_SCHEME = 'http'
mod_wsgi.version = 
mod_wsgi.script_start = '1488435464391480'
mod_wsgi.application_group = 'bugs.saffre-rumma.net|'
mod_wsgi.script_reloading = '1'
mod_wsgi.request_start = '1488435464390824'
HTTP_ACCEPT_ENCODING = 'gzip,deflate,br'
mod_wsgi.daemon_start = '1488435464391329'

Settings:
Using settings module lino_sites.bugs.settings
SECURE_BROWSER_XSS_FILTER = False
USE_X_FORWARDED_PORT = False
USE_THOUSAND_SEPARATOR = False
CSRF_COOKIE_SECURE = False
LANGUAGE_CODE = 'en'
ROOT_URLCONF = u'lino.core.urls'
MANAGERS = []
EMAIL_HOST_PASSWORD = u'********************'
SILENCED_SYSTEM_CHECKS = []
DEFAULT_CHARSET = 'utf-8'
SESSION_SERIALIZER = 'django.contrib.sessions.serializers.JSONSerializer'
STATIC_ROOT = '/var/www/lino/static'
SETUP_INFO = {'message_extractors': {'lino_noi': [('**/cache/**', 'ignore', None), ('**.py', 'python', None), ('**.js', 'javascript', None), ('**/config/**.html', 'jinja2', None)]}, 'description': 'The Lino application used by the Lino team for managing their work on the Lino project', 'license': 'BSD License', 'author': 'Luc Saffre', 'url': 'noi.lino-framework.org', 'include_package_data': True, 'classifiers': ['Programming Language :: Python', 'Programming Language :: Python :: 2', 'Development Status :: 4 - Beta', 'Environment :: Web Environment', 'Framework :: Django', 'Intended Audience :: Developers', 'Intended Audience :: System Administrators', 'Intended Audience :: Information Technology', 'Intended Audience :: Customer Service', 'License :: OSI Approved :: GNU Affero General Public License v3', 'Operating System :: OS Independent', 'Topic :: Software Development :: Bug Tracking'], 'author_email': 'luc@lino-framework.org', 'test_suite': 'tests', 'version': '2017.2.0',
  'zip_safe': False, 'install_requires': ['lino-xl'], 'packages': ['lino_noi', 'lino_noi.lib', 'lino_noi.lib.noi', 'lino_noi.lib.noi.fixtures', 'lino_noi.lib.contacts', 'lino_noi.lib.tickets', 'lino_noi.lib.deploy', 'lino_noi.lib.deploy.fixtures', 'lino_noi.lib.tickets.fixtures', 'lino_noi.lib.faculties', 'lino_noi.lib.clocking', 'lino_noi.lib.clocking.fixtures', 'lino_noi.lib.public', 'lino_noi.lib.users', 'lino_noi.lib.topics', 'lino_noi.lib.users.fixtures', 'lino_noi.lib.votes', 'lino_noi.lib.votes.fixtures', 'lino_noi.projects.bs3', 'lino_noi.projects.bs3.settings', 'lino_noi.projects.bs3.tests', 'lino_noi.projects', 'lino_noi.projects.team', 'lino_noi.projects.team.tests', 'lino_noi.projects.team.settings', 'lino_noi.projects.team.settings.fixtures', 'lino_noi.projects.team.lib', 'lino_noi.projects.team.lib.tickets', 'lino_noi.projects.team.lib.clocking', 'lino_noi.projects.team.lib.clocking.fixtures', 'lino_noi.projects.public', 'lino_noi.projects.care', 'lino_noi.projects.care
 .settings', 'lino_noi.projects.care.settings.fixtures', 'lino_noi.projects.care.tests', 'lino_noi.projects.care.lib', 'lino_noi.projects.care.lib.tickets', 'lino_noi.projects.care_de', 'lino_noi.projects.public.settings', 'lino_noi.projects.public.tests'], 'long_description': '.. image:: readthedocs.org/projects/lino/badge/?version=latest\n    :alt: Documentation Status\n    :target: lino.readthedocs.io/en/latest/?badge=latest\n\n.. image:: coveralls.io/repos/github/khchine5/noi/badge.svg?branch=master\n    :target: coveralls.io/github/khchine5/noi?branch=master\n\n.. image:: travis-ci.org/khchine5/noi.svg?branch=master\n    :target: travis-ci.org/khchine5/noi?branch=master\n\n.. image:: img.shields.io/pypi/v/lino-noi.svg\n    :target: pypi.python.org/pypi/lino-noi/\n\n.. image:: img.shields.io/pypi/l/lino-noi.svg\n    :target: pypi.python.org/pypi/lino-noi/\n\nLino Noi is a customizable ticket management
  and time tracking\nsystem to use when time is more than money.\n\n- For *introductions* and *commercial information* about Lino Noi\n  please see `www.saffre-rumma.net\n  <www.saffre-rumma.net/noi/>;`__.\n\n- The central project homepage is noi.lino-framework.org\n\n\n', 'tests_require': ['pytest', 'mock'], 'name': 'lino-noi'}
ALLOWED_HOSTS = ['bugs.saffre-rumma.net']
MESSAGE_STORAGE = 'django.contrib.messages.storage.fallback.FallbackStorage'
EMAIL_SUBJECT_PREFIX = '[bugs] '
SERVER_EMAIL = 'noreply@saffre-rumma.net'
SECURE_HSTS_SECONDS = 0
STATICFILES_FINDERS = ['django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder']
SESSION_CACHE_ALIAS = 'default'
SESSION_COOKIE_DOMAIN = None
SESSION_COOKIE_NAME = 'sessionid'
TIME_INPUT_FORMATS = ['%H:%M:%S', '%H:%M:%S.%f', '%H:%M']
SECURE_REDIRECT_EXEMPT = []
DATABASES = {'default': {'ENGINE': 'django.db.backends.mysql', 'AUTOCOMMIT': True, 'ATOMIC_REQUESTS': False, 'NAME': 'jane', 'CONN_MAX_AGE': 0, 'TIME_ZONE': None, 'PORT': 3306, 'HOST': 'localhost', 'USER': 'django', 'TEST': {'COLLATION': None, 'CHARSET': None, 'NAME': None, 'MIRROR': None}, 'PASSWORD': u'********************', 'OPTIONS': {}}}
EMAIL_SSL_KEYFILE = u'********************'
FILE_UPLOAD_DIRECTORY_PERMISSIONS = None
FILE_UPLOAD_PERMISSIONS = None
FILE_UPLOAD_HANDLERS = ['django.core.files.uploadhandler.MemoryFileUploadHandler', 'django.core.files.uploadhandler.TemporaryFileUploadHandler']
DEFAULT_CONTENT_TYPE = 'text/html'
APPEND_SLASH = True
LOCALE_PATHS = 
DATABASE_ROUTERS = []
DEFAULT_TABLESPACE = ''
YEAR_MONTH_FORMAT = 'F Y'
STATICFILES_STORAGE = 'django.contrib.staticfiles.storage.StaticFilesStorage'
CACHES = {'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache'}}
SESSION_COOKIE_PATH = '/'
SECURE_CONTENT_TYPE_NOSNIFF = False
MIDDLEWARE_CLASSES = 
USE_I18N = True
THOUSAND_SEPARATOR = ','
SECRET_KEY = u'********************'
LANGUAGE_COOKIE_NAME = 'django_language'
DEFAULT_INDEX_TABLESPACE = ''
SERIALIZATION_MODULES = {u'py': u'lino.utils.dpy'}
LOGGING_CONFIG = 'logging.config.dictConfig'
TEMPLATE_LOADERS = ['django.template.loaders.filesystem.Loader', 'django.template.loaders.app_directories.Loader']
FIRST_DAY_OF_WEEK = 0
WSGI_APPLICATION = None
TEMPLATE_DEBUG = False
X_FRAME_OPTIONS = 'SAMEORIGIN'
AUTHENTICATION_BACKENDS = ['django.contrib.auth.backends.ModelBackend']
TIM2LINO_USERNAME = <function TIM2LINO_USERNAME at 0x7fe390346230>
TIM2LINO_LOCAL = <function TIM2LINO_LOCAL at 0x7fe3903461b8>
FORCE_SCRIPT_NAME = None
USE_X_FORWARDED_HOST = False
CSRF_HEADER_NAME = 'HTTP_X_CSRFTOKEN'
EMAIL_TIMEOUT = None
SECURE_SSL_HOST = None
SIGNING_BACKEND = 'django.core.signing.TimestampSigner'
SESSION_COOKIE_SECURE = False
CSRF_COOKIE_DOMAIN = None
FILE_CHARSET = 'utf-8'
DEBUG = False
CSRF_TRUSTED_ORIGINS = []
LANGUAGE_COOKIE_DOMAIN = None
DEFAULT_FILE_STORAGE = 'django.core.files.storage.FileSystemStorage'
INSTALLED_APPS = 
LANGUAGES = [('de', 'German'), ('en', 'English'), ('et', 'Estonian'), ('fr', 'French')]
USE_L10N = True
SECURE_HSTS_INCLUDE_SUBDOMAINS = False
STATICFILES_DIRS = 
PREPEND_WWW = False
SECURE_PROXY_SSL_HEADER = None
LANGUAGE_COOKIE_AGE = None
SESSION_COOKIE_HTTPONLY = True
DEBUG_PROPAGATE_EXCEPTIONS = False
CSRF_COOKIE_AGE = 31449600
MONTH_DAY_FORMAT = 'F j'
LOGIN_URL = '/accounts/login/'
SESSION_EXPIRE_AT_BROWSER_CLOSE = False
TIME_FORMAT = 'P'
AUTH_USER_MODEL = 'auth.User'
DATE_INPUT_FORMATS = ['%Y-%m-%d', '%m/%d/%Y', '%m/%d/%y', '%b %d %Y', '%b %d, %Y', '%d %b %Y', '%d %b, %Y', '%B %d %Y', '%B %d, %Y', '%d %B %Y', '%d %B, %Y']
CSRF_COOKIE_NAME = 'csrftoken'
AUTH_PASSWORD_VALIDATORS = u'********************'
PASSWORD_RESET_TIMEOUT_DAYS = u'********************'
SESSION_FILE_PATH = None
CACHE_MIDDLEWARE_ALIAS = 'default'
SESSION_SAVE_EVERY_REQUEST = False
NUMBER_GROUPING = 0
SESSION_ENGINE = 'django.contrib.sessions.backends.db'
CSRF_FAILURE_VIEW = 'django.views.csrf.csrf_failure'
CSRF_COOKIE_PATH = '/'
LOGIN_REDIRECT_URL = '/accounts/profile/'
DECIMAL_SEPARATOR = '.'
IGNORABLE_404_URLS = []
MIGRATION_MODULES = {}
SITE = <lino_sites.bugs.settings.Site object at 0x7fe391ae4990>
TEMPLATE_STRING_IF_INVALID = ''
LOGOUT_URL = '/accounts/logout/'
EMAIL_USE_TLS = False
FIXTURE_DIRS = u'/usr/local/python/lino_sites/jane/fixtures'
EMAIL_HOST = 'localhost'
DATE_FORMAT = 'N j, Y'
MEDIA_ROOT = Path('/usr/local/python/lino_sites/bugs/media')
DEFAULT_EXCEPTION_REPORTER_FILTER = 'django.views.debug.SafeExceptionReporterFilter'
ADMINS = [['Luc Saffre', 'luc.saffre@gmx.net'], ['Luc Saffre', 'luc.saffre@gmail.com'], ['Hamza Khchine', 'hamzakhchine@gmail.com'], ['Tonis Piip', 'tonis.piip@gmail.com']]
FORMAT_MODULE_PATH = None
DEFAULT_FROM_EMAIL = 'noreply@saffre-rumma.net'
REST_FRAMEWORK = {'UNAUTHENTICATED_USER': 'lino.modlib.users.utils.AnonymousUser', 'DEFAULT_PERMISSION_CLASSES': ['rest_framework.permissions.IsAuthenticatedOrReadOnly']}
MEDIA_URL = u'/media/'
DATETIME_FORMAT = 'N j, Y, P'
TEMPLATE_DIRS = []
DISALLOWED_USER_AGENTS = []
ALLOWED_INCLUDE_ROOTS = []
LOGGING = {}
SHORT_DATE_FORMAT = 'm/d/Y'
TEMPLATES = [{u'DIRS': [], u'APP_DIRS': True, u'OPTIONS': {u'context_processors': [u'django.template.context_processors.debug', u'django.template.context_processors.i18n', u'django.template.context_processors.media', u'django.template.context_processors.static', u'django.template.context_processors.tz', u'django.contrib.messages.context_processors.messages']}, u'BACKEND': u'django.template.backends.django.DjangoTemplates'}, {u'DIRS': [], u'OPTIONS': {u'environment': u'lino.modlib.jinja.get_environment'}, u'BACKEND': u'django.template.backends.jinja2.Jinja2'}]
TEST_RUNNER = 'django.test.runner.DiscoverRunner'
CACHE_MIDDLEWARE_KEY_PREFIX = u'********************'
SECURE_SSL_REDIRECT = False
TIME_ZONE = 'Europe/Tallinn'
FILE_UPLOAD_MAX_MEMORY_SIZE = 2621440
EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
EMAIL_USE_SSL = False
TEMPLATE_CONTEXT_PROCESSORS = ['django.contrib.auth.context_processors.auth', 'django.template.context_processors.debug', 'django.template.context_processors.i18n', 'django.template.context_processors.media', 'django.template.context_processors.static', 'django.template.context_processors.tz', 'django.contrib.messages.context_processors.messages']
SESSION_COOKIE_AGE = 1209600
SETTINGS_MODULE = 'lino_sites.bugs.settings'
USE_ETAGS = False
LANGUAGES_BIDI = ['he', 'ar', 'fa', 'ur']
FILE_UPLOAD_TEMP_DIR = None
INTERNAL_IPS = []
STATIC_URL = 'static.saffre-rumma.net/'
EMAIL_PORT = 25
USE_TZ = True
SHORT_DATETIME_FORMAT = 'm/d/Y P'
TEST_NON_SERIALIZED_APPS = []
PASSWORD_HASHERS = u'********************'
ABSOLUTE_URL_OVERRIDES = {}
LANGUAGE_COOKIE_PATH = '/'
CACHE_MIDDLEWARE_SECONDS = 600
EMAIL_SSL_CERTFILE = None
CSRF_COOKIE_HTTPONLY = False
DATETIME_INPUT_FORMATS = ['%Y-%m-%d %H:%M:%S', '%Y-%m-%d %H:%M:%S.%f', '%Y-%m-%d %H:%M', '%Y-%m-%d', '%m/%d/%Y %H:%M:%S', '%m/%d/%Y %H:%M:%S.%f', '%m/%d/%Y %H:%M', '%m/%d/%Y', '%m/%d/%y %H:%M:%S', '%m/%d/%y %H:%M:%S.%f', '%m/%d/%y %H:%M', '%m/%d/%y']
EMAIL_HOST_USER = ''


 

Children

Comments