could not translate host name "postgres.cicloturismo" to address: Name or service not known
Request Method: | GET |
---|---|
Request URL: | http://www.sardegnaciclabile.it/ |
Django Version: | 1.10 |
Exception Type: | OperationalError |
Exception Value: | could not translate host name "postgres.cicloturismo" to address: Name or service not known |
Exception Location: | /usr/local/lib/python3.5/dist-packages/psycopg2/__init__.py in connect, line 130 |
Python Executable: | /usr/local/bin/uwsgi |
Python Version: | 3.5.3 |
Python Path: | ['.', '', '/usr/lib/python35.zip', '/usr/lib/python3.5', '/usr/lib/python3.5/plat-x86_64-linux-gnu', '/usr/lib/python3.5/lib-dynload', '/usr/local/lib/python3.5/dist-packages', '/usr/lib/python3/dist-packages'] |
Server time: | Mar, 19 Mar 2024 09:49:11 +0100 |
/usr/local/lib/python3.5/dist-packages/django/db/backends/base/base.py
in ensure_connection
def ensure_connection(self):
"""
Guarantees that a connection to the database is established.
"""
if self.connection is None:
with self.wrap_database_errors:
self.connect()...
# ##### Backend-specific wrappers for PEP-249 connection methods #####
def _cursor(self):
self.ensure_connection()
with self.wrap_database_errors:
Variable | Value |
---|---|
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/django/db/backends/base/base.py
in connect
# Reset parameters defining when to close the connection
max_age = self.settings_dict['CONN_MAX_AGE']
self.close_at = None if max_age is None else time.time() + max_age
self.closed_in_transaction = False
self.errors_occurred = False
# Establish the connection
conn_params = self.get_connection_params()
self.connection = self.get_new_connection(conn_params)...
self.set_autocommit(self.settings_dict['AUTOCOMMIT'])
self.init_connection_state()
connection_created.send(sender=self.__class__, connection=self)
self.run_on_commit = []
Variable | Value |
---|---|
conn_params | {'database': 'cicloturismo_local', 'host': 'postgres.cicloturismo', 'password': 'thepassword', 'port': '5432', 'user': 'postgres'} |
max_age | 0 |
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/django/db/backends/postgresql/base.py
in get_new_connection
if settings_dict['HOST']:
conn_params['host'] = settings_dict['HOST']
if settings_dict['PORT']:
conn_params['port'] = settings_dict['PORT']
return conn_params
def get_new_connection(self, conn_params):
connection = Database.connect(**conn_params)...
# self.isolation_level must be set:
# - after connecting to the database in order to obtain the database's
# default when no value is explicitly specified in options.
# - before calling _set_autocommit() because if autocommit is on, that
# will set connection.isolation_level to ISOLATION_LEVEL_AUTOCOMMIT.
Variable | Value |
---|---|
conn_params | {'database': 'cicloturismo_local', 'host': 'postgres.cicloturismo', 'password': 'thepassword', 'port': '5432', 'user': 'postgres'} |
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/psycopg2/__init__.py
in connect
if 'async_' in kwargs:
kwasync['async_'] = kwargs.pop('async_')
if dsn is None and not kwargs:
raise TypeError('missing dsn and no parameters')
dsn = _ext.make_dsn(dsn, **kwargs)
conn = _connect(dsn, connection_factory=connection_factory, **kwasync)...
if cursor_factory is not None:
conn.cursor_factory = cursor_factory
return conn
Variable | Value |
---|---|
connection_factory | None |
cursor_factory | None |
dsn | ('dbname=cicloturismo_local port=5432 host=postgres.cicloturismo ' 'password=thepassword user=postgres') |
kwargs | {'database': 'cicloturismo_local', 'host': 'postgres.cicloturismo', 'password': 'thepassword', 'port': '5432', 'user': 'postgres'} |
kwasync | {} |
/usr/local/lib/python3.5/dist-packages/django/core/handlers/exception.py
in inner
This decorator is automatically applied to all middleware to ensure that
no middleware leaks an exception and that the next middleware in the stack
can rely on getting a response instead of an exception.
"""
@wraps(get_response, assigned=available_attrs(get_response))
def inner(request):
try:
response = get_response(request)...
except Exception as exc:
response = response_for_exception(request, exc)
return response
return inner
Variable | Value |
---|---|
exc | OperationalError('could not translate host name "postgres.cicloturismo" to address: Name or service not known\n',) |
get_response | <bound method BaseHandler._get_response of <django.core.handlers.wsgi.WSGIHandler object at 0x7f82d036ef28>> |
request | <WSGIRequest: GET '/'> |
/usr/local/lib/python3.5/dist-packages/django/core/handlers/base.py
in _get_response
break
if response is None:
wrapped_callback = self.make_view_atomic(callback)
try:
response = wrapped_callback(request, *callback_args, **callback_kwargs)
except Exception as e:
response = self.process_exception_by_middleware(e, request)...
# Complain if the view returned None (a common error).
if response is None:
if isinstance(callback, types.FunctionType): # FBV
view_name = callback.__name__
else: # CBV
Variable | Value |
---|---|
callback | <function HomeView at 0x7f82cfe22b70> |
callback_args | () |
callback_kwargs | {} |
middleware_method | <bound method CsrfViewMiddleware.process_view of <django.middleware.csrf.CsrfViewMiddleware object at 0x7f82cfe05710>> |
request | <WSGIRequest: GET '/'> |
resolver | <RegexURLResolver 'Cicloturismo.urls' (None:None) ^/> |
resolver_match | ResolverMatch(func=home.views.HomeView, args=(), kwargs={}, url_name=index, app_names=[], namespaces=[]) |
response | None |
self | <django.core.handlers.wsgi.WSGIHandler object at 0x7f82d036ef28> |
wrapped_callback | <function HomeView at 0x7f82cfe22b70> |
/usr/local/lib/python3.5/dist-packages/django/core/handlers/base.py
in _get_response
response = middleware_method(request, callback, callback_args, callback_kwargs)
if response:
break
if response is None:
wrapped_callback = self.make_view_atomic(callback)
try:
response = wrapped_callback(request, *callback_args, **callback_kwargs)...
except Exception as e:
response = self.process_exception_by_middleware(e, request)
# Complain if the view returned None (a common error).
if response is None:
if isinstance(callback, types.FunctionType): # FBV
Variable | Value |
---|---|
callback | <function HomeView at 0x7f82cfe22b70> |
callback_args | () |
callback_kwargs | {} |
middleware_method | <bound method CsrfViewMiddleware.process_view of <django.middleware.csrf.CsrfViewMiddleware object at 0x7f82cfe05710>> |
request | <WSGIRequest: GET '/'> |
resolver | <RegexURLResolver 'Cicloturismo.urls' (None:None) ^/> |
resolver_match | ResolverMatch(func=home.views.HomeView, args=(), kwargs={}, url_name=index, app_names=[], namespaces=[]) |
response | None |
self | <django.core.handlers.wsgi.WSGIHandler object at 0x7f82d036ef28> |
wrapped_callback | <function HomeView at 0x7f82cfe22b70> |
/usr/local/lib/python3.5/dist-packages/django/views/generic/base.py
in view
def view(request, *args, **kwargs):
self = cls(**initkwargs)
if hasattr(self, 'get') and not hasattr(self, 'head'):
self.head = self.get
self.request = request
self.args = args
self.kwargs = kwargs
return self.dispatch(request, *args, **kwargs)...
view.view_class = cls
view.view_initkwargs = initkwargs
# take name and docstring from class
update_wrapper(view, cls, updated=())
Variable | Value |
---|---|
args | () |
cls | <class 'home.views.HomeView'> |
initkwargs | {} |
kwargs | {} |
request | <WSGIRequest: GET '/'> |
self | <home.views.HomeView object at 0x7f82cf794ef0> |
/usr/local/lib/python3.5/dist-packages/django/views/generic/base.py
in dispatch
# Try to dispatch to the right method; if a method doesn't exist,
# defer to the error handler. Also defer to the error handler if the
# request method isn't on the approved list.
if request.method.lower() in self.http_method_names:
handler = getattr(self, request.method.lower(), self.http_method_not_allowed)
else:
handler = self.http_method_not_allowed
return handler(request, *args, **kwargs)...
def http_method_not_allowed(self, request, *args, **kwargs):
logger.warning(
'Method Not Allowed (%s): %s', request.method, request.path,
extra={'status_code': 405, 'request': request}
)
Variable | Value |
---|---|
args | () |
handler | <bound method BaseDetailView.get of <home.views.HomeView object at 0x7f82cf794ef0>> |
kwargs | {} |
request | <WSGIRequest: GET '/'> |
self | <home.views.HomeView object at 0x7f82cf794ef0> |
/usr/local/lib/python3.5/dist-packages/django/views/generic/detail.py
in get
class BaseDetailView(SingleObjectMixin, View):
"""
A base view for displaying a single object
"""
def get(self, request, *args, **kwargs):
self.object = self.get_object()...
context = self.get_context_data(object=self.object)
return self.render_to_response(context)
class SingleObjectTemplateResponseMixin(TemplateResponseMixin):
template_name_field = None
Variable | Value |
---|---|
args | () |
kwargs | {} |
request | <WSGIRequest: GET '/'> |
self | <home.views.HomeView object at 0x7f82cf794ef0> |
./home/views.py
in get_object
model = CicloturismoOptions
template_name = "general_page.html"
def get_object(self, queryset=None):
print("CicloturismoOptionsDetailView")
# self.key = self.kwargs.get('key', None)
obj = CicloturismoOptions.objects.filter(key=self.key).first()...
if obj is None:
titolo = re.sub(r'[_-]+', ' ', self.key)
obj = CicloturismoOptions(key=self.key, name=titolo, value="", group=CT_PAGE_GROUP_CODE)
obj.save()
return obj
Variable | Value |
---|---|
queryset | None |
self | <home.views.HomeView object at 0x7f82cf794ef0> |
/usr/local/lib/python3.5/dist-packages/django/db/models/query.py
in first
def latest(self, field_name=None):
return self._earliest_or_latest(field_name=field_name, direction="-")
def first(self):
"""
Returns the first object of a query, returns None if no match is found.
"""
objects = list((self if self.ordered else self.order_by('pk'))[:1])...
if objects:
return objects[0]
return None
def last(self):
"""
Variable | Value |
---|---|
self | Error in formatting: OperationalError: could not translate host name "postgres.cicloturismo" to address: Name or service not known |
/usr/local/lib/python3.5/dist-packages/django/db/models/query.py
in __iter__
2. sql/compiler.results_iter()
- Returns one row at time. At this point the rows are still just
tuples. In some cases the return values are converted to
Python values at this location.
3. self.iterator()
- Responsible for turning the rows into model objects.
"""
self._fetch_all()...
return iter(self._result_cache)
def __bool__(self):
self._fetch_all()
return bool(self._result_cache)
Variable | Value |
---|---|
self | Error in formatting: OperationalError: could not translate host name "postgres.cicloturismo" to address: Name or service not known |
/usr/local/lib/python3.5/dist-packages/django/db/models/query.py
in _fetch_all
clone._fields = self._fields
clone.__dict__.update(kwargs)
return clone
def _fetch_all(self):
if self._result_cache is None:
self._result_cache = list(self.iterator())...
if self._prefetch_related_lookups and not self._prefetch_done:
self._prefetch_related_objects()
def _next_is_sticky(self):
"""
Indicates that the next filter call and the one following that should
Variable | Value |
---|---|
self | Error in formatting: OperationalError: could not translate host name "postgres.cicloturismo" to address: Name or service not known |
/usr/local/lib/python3.5/dist-packages/django/db/models/query.py
in __iter__
def __iter__(self):
queryset = self.queryset
db = queryset.db
compiler = queryset.query.get_compiler(using=db)
# Execute the query. This will also fill compiler.select, klass_info,
# and annotations.
results = compiler.execute_sql()...
select, klass_info, annotation_col_map = (compiler.select, compiler.klass_info,
compiler.annotation_col_map)
if klass_info is None:
return
model_cls = klass_info['model']
select_fields = klass_info['select_fields']
Variable | Value |
---|---|
compiler | <django.db.models.sql.compiler.SQLCompiler object at 0x7f82cf7a40b8> |
db | 'default' |
queryset | Error in formatting: OperationalError: could not translate host name "postgres.cicloturismo" to address: Name or service not known |
self | <django.db.models.query.ModelIterable object at 0x7f82cf7a4d30> |
/usr/local/lib/python3.5/dist-packages/django/db/models/sql/compiler.py
in execute_sql
raise EmptyResultSet
except EmptyResultSet:
if result_type == MULTI:
return iter([])
else:
return
cursor = self.connection.cursor()...
try:
cursor.execute(sql, params)
except Exception:
cursor.close()
raise
Variable | Value |
---|---|
params | ('home',) |
result_type | 'multi' |
self | <django.db.models.sql.compiler.SQLCompiler object at 0x7f82cf7a40b8> |
sql | ('SELECT "cicloturismo_core_cicloturismooptions"."id", ' '"cicloturismo_core_cicloturismooptions"."created", ' '"cicloturismo_core_cicloturismooptions"."modified", ' '"cicloturismo_core_cicloturismooptions"."key", ' '"cicloturismo_core_cicloturismooptions"."name", ' '"cicloturismo_core_cicloturismooptions"."help_text", ' '"cicloturismo_core_cicloturismooptions"."value", ' '"cicloturismo_core_cicloturismooptions"."group", ' '"cicloturismo_core_cicloturismooptions"."parent_id" FROM ' '"cicloturismo_core_cicloturismooptions" WHERE ' '"cicloturismo_core_cicloturismooptions"."key" = %s ORDER BY ' '"cicloturismo_core_cicloturismooptions"."id" ASC LIMIT 1') |
/usr/local/lib/python3.5/dist-packages/django/db/backends/base/base.py
in cursor
def cursor(self):
"""
Creates a cursor, opening a connection if necessary.
"""
self.validate_thread_sharing()
if self.queries_logged:
cursor = self.make_debug_cursor(self._cursor())...
else:
cursor = self.make_cursor(self._cursor())
return cursor
def commit(self):
"""
Variable | Value |
---|---|
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/django/db/backends/base/base.py
in _cursor
if self.connection is None:
with self.wrap_database_errors:
self.connect()
# ##### Backend-specific wrappers for PEP-249 connection methods #####
def _cursor(self):
self.ensure_connection()...
with self.wrap_database_errors:
return self.create_cursor()
def _commit(self):
if self.connection is not None:
with self.wrap_database_errors:
Variable | Value |
---|---|
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/django/db/backends/base/base.py
in ensure_connection
def ensure_connection(self):
"""
Guarantees that a connection to the database is established.
"""
if self.connection is None:
with self.wrap_database_errors:
self.connect()...
# ##### Backend-specific wrappers for PEP-249 connection methods #####
def _cursor(self):
self.ensure_connection()
with self.wrap_database_errors:
Variable | Value |
---|---|
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/django/db/utils.py
in __exit__
dj_exc_value.__cause__ = exc_value
if not hasattr(exc_value, '__traceback__'):
exc_value.__traceback__ = traceback
# Only set the 'errors_occurred' flag for errors that may make
# the connection unusable.
if dj_exc_type not in (DataError, IntegrityError):
self.wrapper.errors_occurred = True
six.reraise(dj_exc_type, dj_exc_value, traceback)...
def __call__(self, func):
# Note that we are intentionally not using @wraps here for performance
# reasons. Refs #21109.
def inner(*args, **kwargs):
with self:
Variable | Value |
---|---|
db_exc_type | <class 'psycopg2.OperationalError'> |
dj_exc_type | <class 'django.db.utils.OperationalError'> |
dj_exc_value | OperationalError('could not translate host name "postgres.cicloturismo" to address: Name or service not known\n',) |
exc_type | <class 'psycopg2.OperationalError'> |
exc_value | OperationalError('could not translate host name "postgres.cicloturismo" to address: Name or service not known\n',) |
self | <django.db.utils.DatabaseErrorWrapper object at 0x7f82d03bdfd0> |
traceback | <traceback object at 0x7f82cf76b088> |
/usr/local/lib/python3.5/dist-packages/django/utils/six.py
in reraise
if PY3:
exec_ = getattr(moves.builtins, "exec")
def reraise(tp, value, tb=None):
if value is None:
value = tp()
if value.__traceback__ is not tb:
raise value.with_traceback(tb)...
raise value
else:
def exec_(_code_, _globs_=None, _locs_=None):
"""Execute code in a namespace."""
if _globs_ is None:
Variable | Value |
---|---|
tb | <traceback object at 0x7f82cf76b088> |
tp | <class 'django.db.utils.OperationalError'> |
value | OperationalError('could not translate host name "postgres.cicloturismo" to address: Name or service not known\n',) |
/usr/local/lib/python3.5/dist-packages/django/db/backends/base/base.py
in ensure_connection
def ensure_connection(self):
"""
Guarantees that a connection to the database is established.
"""
if self.connection is None:
with self.wrap_database_errors:
self.connect()...
# ##### Backend-specific wrappers for PEP-249 connection methods #####
def _cursor(self):
self.ensure_connection()
with self.wrap_database_errors:
Variable | Value |
---|---|
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/django/db/backends/base/base.py
in connect
# Reset parameters defining when to close the connection
max_age = self.settings_dict['CONN_MAX_AGE']
self.close_at = None if max_age is None else time.time() + max_age
self.closed_in_transaction = False
self.errors_occurred = False
# Establish the connection
conn_params = self.get_connection_params()
self.connection = self.get_new_connection(conn_params)...
self.set_autocommit(self.settings_dict['AUTOCOMMIT'])
self.init_connection_state()
connection_created.send(sender=self.__class__, connection=self)
self.run_on_commit = []
Variable | Value |
---|---|
conn_params | {'database': 'cicloturismo_local', 'host': 'postgres.cicloturismo', 'password': 'thepassword', 'port': '5432', 'user': 'postgres'} |
max_age | 0 |
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/django/db/backends/postgresql/base.py
in get_new_connection
if settings_dict['HOST']:
conn_params['host'] = settings_dict['HOST']
if settings_dict['PORT']:
conn_params['port'] = settings_dict['PORT']
return conn_params
def get_new_connection(self, conn_params):
connection = Database.connect(**conn_params)...
# self.isolation_level must be set:
# - after connecting to the database in order to obtain the database's
# default when no value is explicitly specified in options.
# - before calling _set_autocommit() because if autocommit is on, that
# will set connection.isolation_level to ISOLATION_LEVEL_AUTOCOMMIT.
Variable | Value |
---|---|
conn_params | {'database': 'cicloturismo_local', 'host': 'postgres.cicloturismo', 'password': 'thepassword', 'port': '5432', 'user': 'postgres'} |
self | <django.contrib.gis.db.backends.postgis.base.DatabaseWrapper object at 0x7f82ea50f7b8> |
/usr/local/lib/python3.5/dist-packages/psycopg2/__init__.py
in connect
if 'async_' in kwargs:
kwasync['async_'] = kwargs.pop('async_')
if dsn is None and not kwargs:
raise TypeError('missing dsn and no parameters')
dsn = _ext.make_dsn(dsn, **kwargs)
conn = _connect(dsn, connection_factory=connection_factory, **kwasync)...
if cursor_factory is not None:
conn.cursor_factory = cursor_factory
return conn
Variable | Value |
---|---|
connection_factory | None |
cursor_factory | None |
dsn | ('dbname=cicloturismo_local port=5432 host=postgres.cicloturismo ' 'password=thepassword user=postgres') |
kwargs | {'database': 'cicloturismo_local', 'host': 'postgres.cicloturismo', 'password': 'thepassword', 'port': '5432', 'user': 'postgres'} |
kwasync | {} |
AnonymousUser
No GET data
No POST data
No FILES data
No cookie data
Variable | Value |
---|---|
HTTP_ACCEPT | '*/*' |
HTTP_HOST | 'www.sardegnaciclabile.it' |
HTTP_USER_AGENT | 'claudebot' |
PATH_INFO | '/' |
QUERY_STRING | '' |
REMOTE_ADDR | '34.230.84.106' |
REMOTE_PORT | '52387' |
REQUEST_METHOD | 'GET' |
REQUEST_URI | '/' |
SCRIPT_NAME | '' |
SERVER_NAME | 'ca4d7ac05d71' |
SERVER_PORT | '80' |
SERVER_PROTOCOL | 'HTTP/1.1' |
UWSGI_ROUTER | 'http' |
uwsgi.node | b'ca4d7ac05d71' |
uwsgi.version | b'2.0.17' |
wsgi.errors | <_io.TextIOWrapper name=2 mode='w' encoding='UTF-8'> |
wsgi.file_wrapper | '' |
wsgi.input | <uwsgi._Input object at 0x7f82cfc504c8> |
wsgi.multiprocess | True |
wsgi.multithread | False |
wsgi.run_once | False |
wsgi.url_scheme | 'http' |
wsgi.version | (1, 0) |
Cicloturismo.settings.settings
Setting | Value |
---|---|
ABSOLUTE_URL_OVERRIDES | {} |
ACCOUNT_ACTIVATION_DAYS | 7 |
ADMINS | [] |
ALLOWED_HOSTS | '["*"]' |
ALLOW_EDIT_PROFILE | True |
ALLOW_LOGIN | True |
ANDROID_MIN_VERSION_CODE | 1 |
APPEND_SLASH | True |
APP_NAME | 'production_cicloturismo-web' |
AUTHENTICATION_BACKENDS | ['django.contrib.auth.backends.ModelBackend'] |
AUTH_PASSWORD_VALIDATORS | '********************' |
AUTH_USER_MODEL | 'auth.User' |
AWS_ACCESS_KEY_ID | '********************' |
AWS_DEFAULT_REGION | 'eu-west-3' |
AWS_MEDIA_ROOT | 'https://cicloturismo1.s3.amazonaws.com/production/media' |
AWS_QUERYSTRING_AUTH | False |
AWS_SECRET_ACCESS_KEY | '********************' |
AWS_STORAGE_BUCKET_NAME | 'cicloturismo1' |
BASE_DIR | '/srv/Cicloturismo/Cicloturismo' |
BASE_URL | 'http://sardegnaciclabile.it' |
CACHES | {'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache'}} |
CACHE_MIDDLEWARE_ALIAS | 'default' |
CACHE_MIDDLEWARE_KEY_PREFIX | '********************' |
CACHE_MIDDLEWARE_SECONDS | 600 |
CICLOTURISMO_MAIL | 'sardegnaciclabile@gmail.com' |
CICLOTURISMO_TEL | '070 6756401 - 070 6756405 - 070 6756407' |
CONSTANCE_ADDITIONAL_FIELDS | {'orario_apertura': [<class 'django.forms.fields.ChoiceField'>, {'choices': ((8, '8:00'), (9, '9:00'), (10, '10:00')), 'widget': <django.forms.widgets.Select object at 0x7f82d00706d8>}], 'orario_chiusura': [<class 'django.forms.fields.ChoiceField'>, {'choices': ((18, '18:00'), (19, '19:00'), (20, '20:00'), (21, '21:00')), 'widget': <django.forms.widgets.Select object at 0x7f82d0070710>}]} |
CONSTANCE_BACKEND | 'constance.backends.database.DatabaseBackend' |
CONSTANCE_CONFIG | {'ANDROID_MIN_VERSION_CODE': (1, 'ANDROID_MIN_VERSION_CODE', <class 'int'>), 'CONTACT_EMAIL': (' ', 'Email di contatto alla quale mandare email importanti', <class 'str'>), 'IOS_MIN_VERSION_CODE': (1, 'IOS_MIN_VERSION_CODE', <class 'int'>), 'MATERIAL_FOLDER_DROPBOX': ('https://www.dropbox.com/sh/*******************?dl=1', 'Numero max di eventi in home', <class 'str'>), 'MAX_EVENTS_IN_HOME': (20, 'Numero max di eventi in home', <class 'int'>)} |
CRONJOBS | [('*/30 * * * *', 'cicloturismo_core.users_activations.enabled_users_check')] |
CRONTAB_COMMENT | 'django-crontabs for cicloturismo' |
CSRF_COOKIE_AGE | 31449600 |
CSRF_COOKIE_DOMAIN | None |
CSRF_COOKIE_HTTPONLY | False |
CSRF_COOKIE_NAME | 'csrftoken' |
CSRF_COOKIE_PATH | '/' |
CSRF_COOKIE_SECURE | False |
CSRF_FAILURE_VIEW | 'django.views.csrf.csrf_failure' |
CSRF_HEADER_NAME | 'HTTP_X_CSRFTOKEN' |
CSRF_TRUSTED_ORIGINS | [] |
DATABASES | {'default': {'ATOMIC_REQUESTS': False, 'AUTOCOMMIT': True, 'CONN_MAX_AGE': 0, 'ENGINE': 'django.contrib.gis.db.backends.postgis', 'HOST': 'postgres.cicloturismo', 'NAME': 'cicloturismo_local', 'OPTIONS': {}, 'PASSWORD': '********************', 'PORT': '5432', 'TEST': {'CHARSET': None, 'COLLATION': None, 'MIRROR': None, 'NAME': None}, 'TIME_ZONE': None, 'USER': 'postgres'}} |
DATABASE_ROUTERS | [] |
DATA_UPLOAD_MAX_MEMORY_SIZE | 2621440 |
DATA_UPLOAD_MAX_NUMBER_FIELDS | 1000 |
DATETIME_FORMAT | 'N j, Y, P' |
DATETIME_INPUT_FORMATS | ['%Y-%m-%d %H:%M:%S%d/%m/%Y %H:%M:%S', '%d/%m/%Y'] |
DATE_FORMAT | 'N j, Y' |
DATE_INPUT_FORMATS | ['%Y-%m-%d', '%d/%m/%Y'] |
DEBUG | True |
DEBUG_PROPAGATE_EXCEPTIONS | False |
DECIMAL_SEPARATOR | '.' |
DEFAULT_CHARSET | 'utf-8' |
DEFAULT_CONTACT_EMAIL | ' ' |
DEFAULT_CONTENT_TYPE | 'text/html' |
DEFAULT_EXCEPTION_REPORTER_FILTER | 'django.views.debug.SafeExceptionReporterFilter' |
DEFAULT_FILE_STORAGE | 's3_folder_storage.s3.DefaultStorage' |
DEFAULT_FROM_EMAIL | 'Sardegna Ciclabile <no-reply@sardegnaciclabile.it>' |
DEFAULT_INDEX_TABLESPACE | '' |
DEFAULT_PAYPAL_RECEIVER_EMAIL | 'sardegnaciclabile@gmail.com' |
DEFAULT_PAYPAL_RECHARGE_ITEM_NAME | 'Ricarica_Wallet' |
DEFAULT_PP_BUTTON_ID | '' |
DEFAULT_S3_PATH | 'production/media' |
DEFAULT_TABLESPACE | '' |
DISALLOWED_USER_AGENTS | [] |
DJOSER | {'ACTIVATION_URL': 'dashboard/activate_account/{uid}/{token}', 'PASSWORD_RESET_CONFIRM_URL': '********************', 'PASSWORD_VALIDATORS': '********************', 'SEND_ACTIVATION_EMAIL': True, 'SERIALIZERS': {'user_registration_no_username': 'rest_api.authentication.serializers.CustomUserRegistrationSerializer'}, 'SITE_NAME': 'Cicloturismo'} |
EMAIL_BACKEND | 'django.core.mail.backends.smtp.EmailBackend' |
EMAIL_CONTACTS_TO | '' |
EMAIL_FROM | 'Sardegna Ciclabile <no-reply@sardegnaciclabile.it>' |
EMAIL_HOST | 'smtp.gmail.com' |
EMAIL_HOST_PASSWORD | '********************' |
EMAIL_HOST_USER | 'sardegnaciclabile2022' |
EMAIL_PORT | 587 |
EMAIL_SSL_CERTFILE | None |
EMAIL_SSL_KEYFILE | '********************' |
EMAIL_SUBJECT_PREFIX | '[Django] ' |
EMAIL_TIMEOUT | None |
EMAIL_USE_SSL | False |
EMAIL_USE_TLS | True |
ENVIRONMENT | 'production' |
FB_APP_ID | '253916101845493' |
FB_APP_SITE_URL | 'http://sardegnaciclabile.it' |
FILE_CHARSET | 'utf-8' |
FILE_UPLOAD_DIRECTORY_PERMISSIONS | None |
FILE_UPLOAD_HANDLERS | ['django.core.files.uploadhandler.MemoryFileUploadHandler', 'django.core.files.uploadhandler.TemporaryFileUploadHandler'] |
FILE_UPLOAD_MAX_MEMORY_SIZE | 2621440 |
FILE_UPLOAD_PERMISSIONS | None |
FILE_UPLOAD_TEMP_DIR | None |
FIRST_DAY_OF_WEEK | 0 |
FIXTURE_DIRS | [] |
FORCE_SCRIPT_NAME | None |
FORMAT_MODULE_PATH | None |
GALLERY_UPLOAD_DIR | 'gallery' |
GOOGLE_API_KEY | '********************' |
IGNORABLE_404_URLS | [] |
IGNORE_PAYPAL_VALIDATE_EXCEPTION | True |
IMAGES_MAX_SIZE_PX | 1400 |
INSTALLED_APPS | ['home', 'cicloturismo_core', 'modelcluster', 'taggit', 'django.contrib.admin', 'django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', 'django.contrib.gis', 'rest_framework', 'easy_thumbnails', 'tinymce', 'admin_area', 'purchases', 'constance', 'constance.backends.database', 'mobile_apps', 's3_folder_storage', 'admin_dboard', 'django_log2db', 'django_crontab', 'oauth2_provider', 'colorful', 'microservices_commons'] |
INTERNAL_IPS | [] |
IOS_MIN_VERSION_CODE | 1 |
IVA_PERCENT | 22 |
LANGUAGES | [('af', 'Afrikaans'), ('ar', 'Arabic'), ('ast', 'Asturian'), ('az', 'Azerbaijani'), ('bg', 'Bulgarian'), ('be', 'Belarusian'), ('bn', 'Bengali'), ('br', 'Breton'), ('bs', 'Bosnian'), ('ca', 'Catalan'), ('cs', 'Czech'), ('cy', 'Welsh'), ('da', 'Danish'), ('de', 'German'), ('dsb', 'Lower Sorbian'), ('el', 'Greek'), ('en', 'English'), ('en-au', 'Australian English'), ('en-gb', 'British English'), ('eo', 'Esperanto'), ('es', 'Spanish'), ('es-ar', 'Argentinian Spanish'), ('es-co', 'Colombian Spanish'), ('es-mx', 'Mexican Spanish'), ('es-ni', 'Nicaraguan Spanish'), ('es-ve', 'Venezuelan Spanish'), ('et', 'Estonian'), ('eu', 'Basque'), ('fa', 'Persian'), ('fi', 'Finnish'), ('fr', 'French'), ('fy', 'Frisian'), ('ga', 'Irish'), ('gd', 'Scottish Gaelic'), ('gl', 'Galician'), ('he', 'Hebrew'), ('hi', 'Hindi'), ('hr', 'Croatian'), ('hsb', 'Upper Sorbian'), ('hu', 'Hungarian'), ('ia', 'Interlingua'), ('id', 'Indonesian'), ('io', 'Ido'), ('is', 'Icelandic'), ('it', 'Italian'), ('ja', 'Japanese'), ('ka', 'Georgian'), ('kk', 'Kazakh'), ('km', 'Khmer'), ('kn', 'Kannada'), ('ko', 'Korean'), ('lb', 'Luxembourgish'), ('lt', 'Lithuanian'), ('lv', 'Latvian'), ('mk', 'Macedonian'), ('ml', 'Malayalam'), ('mn', 'Mongolian'), ('mr', 'Marathi'), ('my', 'Burmese'), ('nb', 'Norwegian Bokmål'), ('ne', 'Nepali'), ('nl', 'Dutch'), ('nn', 'Norwegian Nynorsk'), ('os', 'Ossetic'), ('pa', 'Punjabi'), ('pl', 'Polish'), ('pt', 'Portuguese'), ('pt-br', 'Brazilian Portuguese'), ('ro', 'Romanian'), ('ru', 'Russian'), ('sk', 'Slovak'), ('sl', 'Slovenian'), ('sq', 'Albanian'), ('sr', 'Serbian'), ('sr-latn', 'Serbian Latin'), ('sv', 'Swedish'), ('sw', 'Swahili'), ('ta', 'Tamil'), ('te', 'Telugu'), ('th', 'Thai'), ('tr', 'Turkish'), ('tt', 'Tatar'), ('udm', 'Udmurt'), ('uk', 'Ukrainian'), ('ur', 'Urdu'), ('vi', 'Vietnamese'), ('zh-hans', 'Simplified Chinese'), ('zh-hant', 'Traditional Chinese')] |
LANGUAGES_BIDI | ['he', 'ar', 'fa', 'ur'] |
LANGUAGE_CODE | 'it-IT' |
LANGUAGE_COOKIE_AGE | None |
LANGUAGE_COOKIE_DOMAIN | None |
LANGUAGE_COOKIE_NAME | 'django_language' |
LANGUAGE_COOKIE_PATH | '/' |
LOCAL | 'local' |
LOCALE_PATHS | [] |
LOG2DB_ADMIN_EMAIL | ' ' |
LOG2DB_REQUEST_METHODS_TO_LOG | ['POST'] |
LOG2DB_REQUEST_PATH_TO_LOG_STARTSWITH | ['/admin'] |
LOGGING | {'disable_existing_loggers': False, 'filters': {'require_debug_false': {'()': 'django.utils.log.RequireDebugFalse'}}, 'formatters': {'simple': {'format': '[%(asctime)s] [%(levelname)s] ' '%(message)s'}, 'verbose': {'format': '[%(asctime)s];[%(levelname)s];[Proc:%(process)d];[Thread:%(thread)d];%(module)s-%(funcName)s:%(lineno)d;Msg:%(message)s;'}}, 'handlers': {'console': {'class': 'logging.StreamHandler', 'formatter': 'verbose', 'level': 'DEBUG'}, 'file': {'class': 'logging.FileHandler', 'filename': '/srv/Cicloturismo/logs/cicloturismo.log', 'formatter': 'verbose', 'level': 'DEBUG'}, 'mail_admins': {'class': 'django.utils.log.AdminEmailHandler', 'filters': ['require_debug_false'], 'level': 'ERROR'}, 'null': {'class': 'logging.NullHandler', 'level': 'DEBUG'}}, 'loggers': {'cicloturismo': {'handlers': ['console', 'file'], 'level': 'DEBUG', 'propagate': True}, 'django': {'handlers': ['console', 'file'], 'level': 'INFO'}, 'django.request': {'handlers': ['console', 'file'], 'level': 'DEBUG', 'propagate': True}, 'django.security': {'handlers': ['mail_admins', 'file'], 'level': 'ERROR', 'propagate': True}}, 'version': 1} |
LOGGING_CONFIG | 'logging.config.dictConfig' |
LOGIN_REDIRECT_URL | '/accounts/profile/' |
LOGIN_URL | '/accounts/login/' |
LOGOUT_REDIRECT_URL | None |
LOG_DIR | '/srv/Cicloturismo/logs' |
LOG_FILE | '/srv/Cicloturismo/logs/cicloturismo.log' |
MANAGERS | [] |
MAX_UPLOAD_SIZE | 5242880 |
MEDIA_ROOT | '/production/media/' |
MEDIA_URL | '/media/' |
MESSAGE_STORAGE | 'django.contrib.messages.storage.fallback.FallbackStorage' |
MIDDLEWARE | ['django.contrib.sessions.middleware.SessionMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.auth.middleware.SessionAuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware', 'django.middleware.security.SecurityMiddleware', 'Cicloturismo.middleware.log_request_middleware.ProcessRequestMiddleware'] |
MIDDLEWARE_CLASSES | ['django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware'] |
MIGRATION_MODULES | {} |
MODULE_NAME | 'cicloturismo-web' |
MONTH_DAY_FORMAT | 'F j' |
NEARBY_MAX_ITEMS | 10 |
NEARBY_RADIUS_METERS | 50000 |
NEEDS_ACTIVATION_FROM_EMAIL | True |
NUMBER_GROUPING | 0 |
PASSWORD_HASHERS | '********************' |
PASSWORD_RESET_TIMEOUT_DAYS | '********************' |
PAYPAL_BUTTON_SUBMIT_URL | 'https://www.sandbox.paypal.com/cgi-bin/webscr' |
PAYPAL_IPN_VALIDATE_URL | 'https://www.sandbox.paypal.com/cgi-bin/webscr?cmd=_notify-validate' |
PDF_UPLOAD_DIR | 'pdf' |
PREPEND_WWW | False |
PRODUCTION | 'production' |
PROJECT_DIR | '/srv/Cicloturismo/Cicloturismo' |
RAG_SOC | '[rag-soc]' |
RAG_SOC_ADDRESS | '[rag-soc-addr]' |
RAG_SOC_CF | '[rag-soc-cf]' |
RAG_SOC_PI | '[rag-soc-pi]' |
REQUEST_UPLOAD_DIR | 'requests' |
REST_FRAMEWORK | {'DATETIME_FORMAT': '%Y-%m-%d %H:%M:%S', 'DEFAULT_AUTHENTICATION_CLASSES': ('rest_framework.authentication.TokenAuthentication', 'Cicloturismo.auth.CsrfExemptSessionAuthentication', 'rest_framework.authentication.SessionAuthentication', 'oauth2_provider.ext.rest_framework.OAuth2Authentication'), 'DEFAULT_FILTER_BACKENDS': ('rest_framework.filters.DjangoFilterBackend', 'django_filters.rest_framework.DjangoFilterBackend'), 'DEFAULT_PAGINATION_CLASS': 'rest_framework.pagination.LimitOffsetPagination', 'EXCEPTION_HANDLER': 'rest_api.rest_utils.custom_exception_handler', 'PAGE_SIZE': 10} |
ROOT_URLCONF | 'Cicloturismo.urls' |
SECRET_KEY | '********************' |
SECURE_BROWSER_XSS_FILTER | False |
SECURE_CONTENT_TYPE_NOSNIFF | False |
SECURE_HSTS_INCLUDE_SUBDOMAINS | False |
SECURE_HSTS_SECONDS | 0 |
SECURE_PROXY_SSL_HEADER | None |
SECURE_REDIRECT_EXEMPT | [] |
SECURE_SSL_HOST | None |
SECURE_SSL_REDIRECT | False |
SERVER_EMAIL | 'root@localhost' |
SESSION_CACHE_ALIAS | 'default' |
SESSION_COOKIE_AGE | 1209600 |
SESSION_COOKIE_DOMAIN | None |
SESSION_COOKIE_HTTPONLY | True |
SESSION_COOKIE_NAME | 'sessionid' |
SESSION_COOKIE_PATH | '/' |
SESSION_COOKIE_SECURE | False |
SESSION_ENGINE | 'django.contrib.sessions.backends.db' |
SESSION_EXPIRE_AT_BROWSER_CLOSE | False |
SESSION_FILE_PATH | None |
SESSION_SAVE_EVERY_REQUEST | False |
SESSION_SERIALIZER | 'django.contrib.sessions.serializers.JSONSerializer' |
SETTINGS_MODULE | 'Cicloturismo.settings.settings' |
SHORT_DATETIME_FORMAT | 'm/d/Y P' |
SHORT_DATE_FORMAT | 'm/d/Y' |
SHOW_ADS | False |
SIGNING_BACKEND | 'django.core.signing.TimestampSigner' |
SILENCED_SYSTEM_CHECKS | [] |
SITE_DESC | 'Rete Ciclabile della Sardegna' |
SITE_NAME | 'Sardegna Ciclabile' |
SITE_URL | 'https://www.sardegnaciclabile.it/' |
STAGE | 'stage' |
STATICFILES_DIRS | ['/srv/Cicloturismo/Cicloturismo/static'] |
STATICFILES_FINDERS | ['django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder'] |
STATICFILES_STORAGE | 'django.contrib.staticfiles.storage.StaticFilesStorage' |
STATIC_ROOT | '/srv/Cicloturismo/static' |
STATIC_ROOT_SITE | '/srv/Cicloturismo/Cicloturismo/static/cicloturismo_core/' |
STATIC_URL | '/static/' |
TEMPLATES | [{'APP_DIRS': True, 'BACKEND': 'django.template.backends.django.DjangoTemplates', 'DIRS': ['/srv/Cicloturismo/Cicloturismo/templates'], 'OPTIONS': {'context_processors': ['django.template.context_processors.debug', 'django.template.context_processors.request', 'django.contrib.auth.context_processors.auth', 'django.contrib.messages.context_processors.messages']}}] |
TEMP_FILES_DIR | '/srv/Cicloturismo/temp_files' |
TEST_NON_SERIALIZED_APPS | [] |
TEST_RUNNER | 'django.test.runner.DiscoverRunner' |
THOUSAND_SEPARATOR | ',' |
THUMBNAIL_ALIASES | {'': {'avatar': {'crop': True, 'size': (800, 533)}, 'rectangular': {'crop': True, 'size': (800, 300)}, 'rectangular_big': {'crop': True, 'size': (950, 400)}, 'square': {'crop': True, 'size': (400, 400)}, 'square_small': {'crop': True, 'size': (200, 200)}}} |
THUMBNAIL_DEFAULT_STORAGE | 's3_folder_storage.s3.DefaultStorage' |
TIME_FORMAT | 'P' |
TIME_INPUT_FORMATS | ['%H:%M:%S', '%H:%M:%S.%f', '%H:%M'] |
TIME_ZONE | 'Europe/Rome' |
TINYMCE_COMPRESSOR | True |
TINYMCE_DEFAULT_CONFIG | {'cleanup_on_startup': True, 'custom_undo_redo_levels': 10, 'plugins': 'table,paste,searchreplace'} |
TINYMCE_SPELLCHECKER | True |
UPLOAD_DIR | 'files/%Y/%m/%d' |
USE_ETAGS | False |
USE_I18N | True |
USE_L10N | True |
USE_THOUSAND_SEPARATOR | False |
USE_TZ | True |
USE_X_FORWARDED_HOST | False |
USE_X_FORWARDED_PORT | False |
WAGTAIL_SITE_NAME | 'Sardegna Ciclabile' |
WSGI_APPLICATION | 'Cicloturismo.wsgi.application' |
X_FRAME_OPTIONS | 'SAMEORIGIN' |
YEAR_MONTH_FORMAT | 'F Y' |
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 page generated by the handler for this status code.