NameError at /de/events/2019/3/14/

global name 'timezone' is not defined
Request Method: GET
Request URL: https://www.hausappenzell.ch/de/events/2019/3/14/
Django Version: 1.6.11
Exception Type: NameError
Exception Value:
global name 'timezone' is not defined
Exception Location: /tmp/hausappenzell-extensions/hausappenzell_extensions/utils.py in build_calendar_context, line 66
Python Executable: /usr/local/bin/uwsgi
Python Version: 2.7.12
Python Path:
['/srv/www/haap-website/',
 '.',
 '',
 '/tmp/hausappenzell-extensions',
 '/srv/virtualenvs/haap-live/lib/python2.7',
 '/srv/virtualenvs/haap-live/lib/python2.7/plat-x86_64-linux-gnu',
 '/srv/virtualenvs/haap-live/lib/python2.7/lib-tk',
 '/srv/virtualenvs/haap-live/lib/python2.7/lib-old',
 '/srv/virtualenvs/haap-live/lib/python2.7/lib-dynload',
 '/usr/lib/python2.7',
 '/usr/lib/python2.7/plat-x86_64-linux-gnu',
 '/usr/lib/python2.7/lib-tk',
 '/srv/virtualenvs/haap-live/local/lib/python2.7/site-packages',
 '/srv/virtualenvs/haap-live/lib/python2.7/site-packages']
Server time: Di, 19 Mär 2024 09:46:12 +0100

Error during template rendering

In template /srv/www/haap-website/templates/aldryn_events/plugins/calendar.html, error at line 10

global name 'timezone' is not defined

1 {% load aldryn_events hausappenzell_extras %}
2
3 <div class="aldryn aldryn-events aldryn-events-calendar box alpha omega grid_7">
4 <div class="box_inner less_space">
5 {% if plugin_configuration_error %}
6 {% if request.user.is_staff or request.user.is_superuser %}
7 <p class="config-errors">{{ plugin_configuration_error }}</p>
8 {% endif %}
9 {% else %}
10 {% haus_app_calendar event_year event_month calendar_language calendar_namespace %}
11 {% endif %}
12 </div>
13 </div>
14

Traceback Switch to copy-and-paste view



Request information

GET

No GET data

POST

No POST data

FILES

No FILES data

No cookie data

META

Variable Value
wsgi.multiprocess
True
SCRIPT_NAME
u''
REQUEST_METHOD
'GET'
PATH_INFO
u'/de/events/2019/3/14/'
SERVER_PROTOCOL
'HTTP/2.0'
QUERY_STRING
''
CONTENT_LENGTH
''
HTTP_USER_AGENT
'claudebot'
SERVER_NAME
'www.hausappenzell.ch'
REMOTE_ADDR
'54.227.136.157'
wsgi.url_scheme
'https'
Host
'esoteric'
SERVER_PORT
'443'
uwsgi.node
'esoteric'
SERVER_ADDR
'10.100.102.126'
DOCUMENT_ROOT
'/usr/share/nginx/html'
uwsgi.core
5
wsgi.input
<uwsgi._Input object at 0x7f00524ea588>
HTTP_HOST
'www.hausappenzell.ch'
HTTPS
'on'
wsgi.multithread
True
REQUEST_URI
'/de/events/2019/3/14/'
HTTP_ACCEPT
'*/*'
wsgi.version
(1, 0)
wsgi.run_once
False
X-Forwarded-For
'54.227.136.157'
REMOTE_PORT
'54680'
REQUEST_SCHEME
'https'
uwsgi.version
'2.0.17'
X-Forwarded-Proto
''
CONTENT_TYPE
''
X-Real-IP
'54.227.136.157'
wsgi.file_wrapper
''
CSRF_COOKIE
u'tZYQM3D8uME6EEGa3D1PcT0IrHj43sNb'
wsgi.errors
<open file 'wsgi_errors', mode 'w' at 0x7f007b1bfdb0>

Settings

Using settings module haap.settings

Setting Value
USE_L10N
True
THUMBNAIL_PROCESSORS
('easy_thumbnails.processors.colorspace',
 'easy_thumbnails.processors.autocrop',
 'filer.thumbnail_processors.scale_and_crop_with_subject_location',
 'easy_thumbnails.processors.filters')
TIME_ZONE
'Europe/Zurich'
CSRF_COOKIE_SECURE
False
LANGUAGE_CODE
'de'
ROOT_URLCONF
'haap.urls'
LOGIN_URL
'/accounts/login/'
BASE_DIR
'/srv/www/haap-website'
DEFAULT_CHARSET
'utf-8'
SESSION_SERIALIZER
'django.contrib.sessions.serializers.JSONSerializer'
STATIC_ROOT
'/srv/www/haap-website/static'
USE_THOUSAND_SEPARATOR
False
ALLOWED_HOSTS
['localhost', '*']
MESSAGE_STORAGE
'django.contrib.messages.storage.fallback.FallbackStorage'
EMAIL_SUBJECT_PREFIX
'[Django] '
SEND_BROKEN_LINK_EMAILS
False
STATICFILES_FINDERS
['django.contrib.staticfiles.finders.FileSystemFinder',
 'aldryn_boilerplates.staticfile_finders.AppDirectoriesFinder',
 'django.contrib.staticfiles.finders.AppDirectoriesFinder']
SESSION_CACHE_ALIAS
'default'
SESSION_COOKIE_DOMAIN
None
SESSION_COOKIE_NAME
'sessionid'
EMAIL_BACKEND
'django.core.mail.backends.smtp.EmailBackend'
ADMIN_FOR
()
TIME_INPUT_FORMATS
('%H:%M:%S', '%H:%M:%S.%f', '%H:%M')
DATABASES
{'default': {'ADMINUSER': 'postgres',
             'ATOMIC_REQUESTS': False,
             'AUTOCOMMIT': True,
             'CONN_MAX_AGE': 120,
             'ENGINE': 'django.db.backends.postgresql_psycopg2',
             'HOST': 'memoremix',
             'NAME': 'haap_live',
             'OPTIONS': {},
             'PASSWORD': u'********************',
             'PORT': '',
             'TEST_CHARSET': None,
             'TEST_COLLATION': None,
             'TEST_MIRROR': None,
             'TEST_NAME': None,
             'TIME_ZONE': 'UTC',
             'USER': 'haap'}}
FILE_UPLOAD_PERMISSIONS
None
FILE_UPLOAD_HANDLERS
('django.core.files.uploadhandler.MemoryFileUploadHandler',
 'django.core.files.uploadhandler.TemporaryFileUploadHandler')
DEFAULT_CONTENT_TYPE
'text/html'
CAPTCHA_LETTER_ROTATION
None
APPEND_SLASH
True
FIRST_DAY_OF_WEEK
0
DATABASE_ROUTERS
[]
YEAR_MONTH_FORMAT
'F Y'
STATICFILES_STORAGE
'django.contrib.staticfiles.storage.StaticFilesStorage'
CACHES
{'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache'}}
PROJECT_HOME
'/srv/www/haap-website'
SERVER_EMAIL
'root@localhost'
SESSION_COOKIE_PATH
'/'
CMS_TEMPLATES
(('fullwidth.html', 'full width'),
 ('sidebar_left.html', 'sidebar left'),
 ('sidebar_right.html', 'sidebar right'),
 ('tpl_home.html', 'home template'),
 ('tpl_col-one.html', 'col one'),
 ('tpl_col-two-box.html', 'col two box'),
 ('tpl_col-two-prefix.html', 'col two prefix'),
 ('tpl_col-two-presuf.html', 'two col presuf'),
 ('tpl_col-two.html', 'col two'),
 ('tpl_col-two-suffix.html', 'col two suffix'),
 ('tpl_only-feature.html', 'OnlyFeature'))
MIDDLEWARE_CLASSES
('django.contrib.sessions.middleware.SessionMiddleware',
 'django.middleware.csrf.CsrfViewMiddleware',
 'django.contrib.auth.middleware.AuthenticationMiddleware',
 'django.contrib.messages.middleware.MessageMiddleware',
 'django.middleware.locale.LocaleMiddleware',
 'django.middleware.common.CommonMiddleware',
 'cms.middleware.user.CurrentUserMiddleware',
 'cms.middleware.page.CurrentPageMiddleware',
 'cms.middleware.toolbar.ToolbarMiddleware',
 'cms.middleware.language.LanguageCookieMiddleware')
USE_I18N
True
THOUSAND_SEPARATOR
','
CMS_LANGUAGES
{1: [{'code': 'de',
      'fallbacks': ['en'],
      'hide_untranslated': True,
      'name': 'de',
      'public': True,
      'redirect_on_fallback': True},
     {'code': 'en',
      'fallbacks': ['de'],
      'hide_untranslated': True,
      'name': 'en',
      'public': True,
      'redirect_on_fallback': True}],
 <class cms.utils.conf.VERIFIED at 0x7f007812c4c8>: True,
 'default': {'hide_untranslated': True,
             'public': True,
             'redirect_on_fallback': True}}
ALDRYN_BOOTSTRAP3_ICONSETS
[('glyphicons', 'glyphicons', 'Glyphicons'),
 ('fontawesome', 'fa', 'Fontawesome')]
THUMBNAIL_SOURCE_GENERATORS
('easy_thumbnails.source_generators.pil_image',)
LANGUAGE_COOKIE_NAME
'django_language'
DEFAULT_INDEX_TABLESPACE
''
TRANSACTIONS_MANAGED
False
LOGGING_CONFIG
'django.utils.log.dictConfig'
CMSPLUGIN_FILER_IMAGE_STYLE_CHOICES
()
TEMPLATE_LOADERS
['django.template.loaders.filesystem.Loader',
 'aldryn_boilerplates.template_loaders.AppDirectoriesLoader',
 'django.template.loaders.app_directories.Loader']
THUMBNAIL_CACHE_DIMENSIONS
True
WSGI_APPLICATION
'haap.wsgi.application'
CKEDITOR_SETTINGS
{'extraPlugins': 'cmsplugins',
 'height': 300,
 'language': '{{ language }}',
 'skin': 'moono',
 'toolbar': 'CMS',
 'toolbar_HTMLField': [['Undo', 'Redo'],
                       ['cmsplugins', '-', 'ShowBlocks'],
                       ['Format', 'Styles'],
                       ['TextColor',
                        'BGColor',
                        '-',
                        'PasteText',
                        'PasteFromWord'],
                       ['Maximize', ''],
                       '/',
                       ['Bold',
                        'Italic',
                        'Underline',
                        '-',
                        'Subscript',
                        'Superscript',
                        '-',
                        'RemoveFormat'],
                       ['JustifyLeft', 'JustifyCenter', 'JustifyRight'],
                       ['HorizontalRule'],
                       ['Link', 'Unlink'],
                       ['NumberedList',
                        'BulletedList',
                        '-',
                        'Outdent',
                        'Indent',
                        '-',
                        'Table'],
                       ['Source'],
                       ['Link', 'Unlink', 'Anchor']]}
TEMPLATE_DEBUG
True
X_FRAME_OPTIONS
'SAMEORIGIN'
CSRF_COOKIE_NAME
'csrftoken'
FORCE_SCRIPT_NAME
None
USE_X_FORWARDED_HOST
False
SIGNING_BACKEND
'django.core.signing.TimestampSigner'
SESSION_COOKIE_SECURE
False
CSRF_COOKIE_DOMAIN
None
FILE_CHARSET
'utf-8'
DEBUG
True
SESSION_FILE_PATH
None
DEFAULT_FILE_STORAGE
'django.core.files.storage.FileSystemStorage'
INSTALLED_APPS
('djangocms_admin_style',
 'django.contrib.admin',
 'django.contrib.auth',
 'django.contrib.contenttypes',
 'django.contrib.sessions',
 'django.contrib.messages',
 'django.contrib.sites',
 'django.contrib.staticfiles',
 'django.contrib.sitemaps',
 'south',
 'cms',
 'mptt',
 'menus',
 'sekizai',
 'reversion',
 'hvad',
 'parler',
 'filer',
 'robots',
 'easy_thumbnails',
 'polymorphic',
 'djangocms_text_ckeditor',
 'djangocms_link',
 'djangocms_snippet',
 'djangocms_googlemap',
 'cmsplugin_filer_file',
 'cmsplugin_filer_image',
 'captcha',
 'django_select2',
 'aldryn_apphooks_config',
 'aldryn_boilerplates',
 'aldryn_common',
 'aldryn_events',
 'aldryn_translation_tools',
 'appconf',
 'bootstrap3',
 'django_tablib',
 'extended_choices',
 'sortedm2m',
 'standard_form',
 'emailit',
 'aldryn_mailchimp',
 'aldryn_forms',
 'aldryn_forms.contrib.email_notifications',
 'aldryn_video',
 'tinymce',
 'hausappenzell_extensions',
 'simplegallery',
 'haap')
ALDRYN_EVENTS_TEASER_TEMPLATE_CHOICES
(('default', <django.utils.functional.__proxy__ object at 0x7f005a0ea310>),)
LANGUAGES_BIDI
('he', 'ar', 'fa', 'ur')
COMMENTS_ALLOW_PROFANITIES
False
EMAIL_HOST_USER
'support@nephila.ch'
STATICFILES_DIRS
()
ALDRYN_EVENTS_DEFAULT_FROM_EMAIL
'info@hausappenzell.ch'
PREPEND_WWW
False
SECURE_PROXY_SSL_HEADER
None
SESSION_COOKIE_HTTPONLY
True
PARLER_LANGUAGES
{1: ({'code': 'de', 'fallbacks': ['de'], 'hide_untranslated': False},
     {'code': 'en', 'fallbacks': ['de'], 'hide_untranslated': False}),
 'default': {'code': 'de', 'fallbacks': ['de'], 'hide_untranslated': False}}
DEBUG_PROPAGATE_EXCEPTIONS
False
MONTH_DAY_FORMAT
'F j'
MANAGERS
()
SESSION_EXPIRE_AT_BROWSER_CLOSE
False
TINYMCE_JS_URL
'/static/js/tinymce/tiny_mce.js'
TIME_FORMAT
'P'
ALDRYN_EVENTS_MANAGERS
()
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')
AUTHENTICATION_BACKENDS
('django.contrib.auth.backends.ModelBackend',)
EMAIL_HOST_PASSWORD
u'********************'
PASSWORD_RESET_TIMEOUT_DAYS
u'********************'
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
'/'
CMSPLUGIN_FILER_IMAGE_DEFAULT_STYLE
''
THUMBNAIL_PRESERVE_EXTENSIONS
['png', 'gif']
DECIMAL_SEPARATOR
'.'
IGNORABLE_404_URLS
()
LOCALE_PATHS
()
ALDRYN_EVENTS_MANAGER_REGISTRATION_EMAIL
False
TEMPLATE_STRING_IF_INVALID
''
THUMBNAIL_HIGH_RESOLUTION
False
LOGOUT_URL
'/accounts/logout/'
EMAIL_USE_TLS
True
LOGIN_REDIRECT_URL
'/accounts/profile/'
FIXTURE_DIRS
()
EMAIL_HOST
'sicuro.nephila.it'
DATE_FORMAT
'N j, Y'
FB_APP_ID
'20531316728'
MEDIA_ROOT
'/srv/www/haap-website/dist/media'
CMSPLUGIN_FILER_FILE_DEFAULT_STYLE
''
DEFAULT_EXCEPTION_REPORTER_FILTER
'django.views.debug.SafeExceptionReporterFilter'
ADMINS
()
FORMAT_MODULE_PATH
None
DEFAULT_FROM_EMAIL
'info@hausappenzell.ch'
MEDIA_URL
'/media/'
DATETIME_FORMAT
'N j, Y, P'
TEMPLATE_DIRS
('/srv/www/haap-website/templates',)
SITE_ID
1
DISALLOWED_USER_AGENTS
()
ALLOWED_INCLUDE_ROOTS
()
LOGGING
{}
SHORT_DATE_FORMAT
'm/d/Y'
SECRET_KEY
u'********************'
THUMBNAIL_QUALITY
90
TEST_RUNNER
'django.test.runner.DiscoverRunner'
CACHE_MIDDLEWARE_KEY_PREFIX
u'********************'
CMSPLUGIN_FILER_FILE_STYLE_CHOICES
()
FILE_UPLOAD_MAX_MEMORY_SIZE
2621440
CAPTCHA_NOISE_FUNCTIONS
('captcha.helpers.noise_null', 'captcha.helpers.noise_null')
ALDRYN_BOILERPLATE_NAME
'bootstrap3'
DEFAULT_TABLESPACE
''
TEMPLATE_CONTEXT_PROCESSORS
('django.contrib.auth.context_processors.auth',
 'django.core.context_processors.debug',
 'django.core.context_processors.i18n',
 'django.core.context_processors.media',
 'django.core.context_processors.static',
 'django.core.context_processors.tz',
 'django.contrib.messages.context_processors.messages',
 'django.core.context_processors.request',
 'sekizai.context_processors.sekizai',
 'cms.context_processors.cms_settings',
 'aldryn_boilerplates.context_processors.boilerplate')
SESSION_COOKIE_AGE
1209600
SETTINGS_MODULE
'haap.settings'
USE_ETAGS
False
LANGUAGES
[('de', 'Deutsch'), ('en', 'English')]
FILE_UPLOAD_TEMP_DIR
None
INTERNAL_IPS
['127.0.0.1']
STATIC_URL
'/static/'
EMAIL_PORT
'587'
USE_TZ
True
SHORT_DATETIME_FORMAT
'm/d/Y P'
PASSWORD_HASHERS
u'********************'
TINYMCE_DEFAULT_CONFIG
{'cleanup': True,
 'cleanup_on_startup': True,
 'convert_fonts_to_spans': False,
 'convert_urls': False,
 'extended_valid_elements': 'a[class|name|href|title|onclick|target],img[class|src|alt=image|id|title|onmouseover|onmouseout],p[id|style|dir|class],span[class|style],br[class|clear<all?left?none?right|id|style|title]',
 'fix_nesting': True,
 'forced_root_block': 'p',
 'gecko_spellcheck': False,
 'height': '300',
 'invalid_elements': 'font,strike,u',
 'object_resizing': False,
 'paste_remove_spans': True,
 'paste_remove_styles': True,
 'plugins': 'advimage,advlink,table,searchreplace,contextmenu,paste,save,autosave,template',
 'removeformat_selector': 'b,strong,em,i,span,ins',
 'show_styles_menu': False,
 'skin': 'o2k7',
 'style_formats': [{'title': 'Text styles'},
                   {'classes': 'align-left',
                    'selector': 'p,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img',
                    'title': 'Text left'},
                   {'classes': 'align-right',
                    'selector': 'p,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img',
                    'title': 'Text right'},
                   {'classes': 'align-center',
                    'selector': 'p,h2,h3,h4,h5,h6,td,th,div,ul,ol,li,table,img',
                    'title': 'Text center'},
                   {'title': 'Object styles'},
                   {'classes': 'left',
                    'selector': 'p,h2,h3,h4,h5,h6,div,ul,ol,table,img',
                    'title': 'Float left'},
                   {'classes': 'right',
                    'selector': 'p,h2,h3,h4,h5,h6,div,ul,ol,table,img',
                    'title': 'Float right'},
                   {'classes': 'clear',
                    'selector': 'p,h2,h3,h4,h5,h6,div,ul,ol,table,img',
                    'title': 'Clear'},
                   {'title': 'Additional styles'},
                   {'classes': 'target:blank',
                    'selector': 'p,h2,h3,h4,h5,h6,div,ul,ol,table,img',
                    'title': 'Link in new window'}],
 'theme': 'advanced',
 'theme_advanced_blockformats': 'p,h2,h3,h4,h5,h6',
 'theme_advanced_buttons1': 'formatselect,styleselect,separator,removeformat,template,separator,code,cleanup',
 'theme_advanced_buttons2': 'pastetext,pasteword,separator,bold,italic,separator,bullist,numlist,separator,link,unlink,anchor,separator,tablecontrols',
 'theme_advanced_buttons3': '',
 'theme_advanced_resizing': False,
 'theme_advanced_statusbar_location': 'bottom',
 'theme_advanced_toolbar_align': 'left',
 'theme_advanced_toolbar_location': 'top',
 'visual': True,
 'width': '640'}
ABSOLUTE_URL_OVERRIDES
{}
ALDRYN_EVENTS_USER_REGISTRATION_EMAIL
False
CACHE_MIDDLEWARE_SECONDS
600
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')
MAILCHIMP_API_KEY
u'********************'
PROFANITIES_LIST
u'********************'

You're seeing this error because you have DEBUG = True in your Django settings file. Change that to False, and Django will display a standard 500 page.