· 5 years ago · Jan 27, 2020, 11:44 PM
1SUCCESS: AttributeError at /groups/2/candidates/
2'CandidatesQuery' object has no attribute 'prestart'
3
4Request Method: GET
5Request URL: http://95.213.252.8/groups/2/candidates/
6Django Version: 2.2.9
7Python Executable: /root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/bin/python
8Python Version: 3.7.3
9Python Path: ['/app', '/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/bin', '/usr/local/lib/python37.zip', '/usr/local/lib/python3.7', '/usr/local/lib/python3.7/lib-dynload', '/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages', '/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/src/clickhouse-driver', '/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/src/pysendpulse', '/app']
10Server time: Mon, 27 Jan 2020 23:39:39 +0000
11Installed Applications:
12['django.contrib.auth',
13 'django.contrib.contenttypes',
14 'django.contrib.sessions',
15 'django.contrib.messages',
16 'django.contrib.staticfiles',
17 'django.contrib.admin',
18 'drf_yasg',
19 'rest_framework.authtoken',
20 'corsheaders',
21 'colorful',
22 'push_notifications',
23 'django_celery_beat',
24 'authorization',
25 'mentions',
26 'administration',
27 'app']
28Installed Middleware:
29['django.middleware.security.SecurityMiddleware',
30 'django.contrib.sessions.middleware.SessionMiddleware',
31 'corsheaders.middleware.CorsMiddleware',
32 'django.middleware.common.CommonMiddleware',
33 'django.middleware.csrf.CsrfViewMiddleware',
34 'django.contrib.auth.middleware.AuthenticationMiddleware',
35 'django.contrib.messages.middleware.MessageMiddleware',
36 'django.middleware.clickjacking.XFrameOptionsMiddleware']
37
38
39Traceback:
40
41File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/django/core/handlers/exception.py" in inner
42 34. response = get_response(request)
43
44File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/django/core/handlers/base.py" in _get_response
45 115. response = self.process_exception_by_middleware(e, request)
46
47File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/django/core/handlers/base.py" in _get_response
48 113. response = wrapped_callback(request, *callback_args, **callback_kwargs)
49
50File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/django/views/decorators/csrf.py" in wrapped_view
51 54. return view_func(*args, **kwargs)
52
53File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/django/views/generic/base.py" in view
54 71. return self.dispatch(request, *args, **kwargs)
55
56File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/rest_framework/views.py" in dispatch
57 505. response = self.handle_exception(exc)
58
59File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/rest_framework/views.py" in handle_exception
60 465. self.raise_uncaught_exception(exc)
61
62File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/rest_framework/views.py" in raise_uncaught_exception
63 476. raise exc
64
65File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/rest_framework/views.py" in dispatch
66 502. response = handler(request, *args, **kwargs)
67
68File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/django/utils/decorators.py" in _wrapper
69 45. return bound_method(*args, **kwargs)
70
71File "/root/.cache/pypoetry/virtualenvs/rephouse-backend-9TtSrW0h-py3.7/lib/python3.7/site-packages/django/views/decorators/cache.py" in _wrapped_view_func
72 44. response = view_func(request, *args, **kwargs)
73
74File "/app/mentions/views/__init__.py" in get
75 291. } for candidate in self.get_queryset()], status=200)
76
77File "/app/mentions/views/__init__.py" in get_queryset
78 269. project_id=self.get_user_project_id(),
79
80File "/app/rephouse_backend/clickhouse/aggregations/queries/mentions.py" in query
81 47. '''.format(self.base_fields_filter), self.fields_filter_values)
82
83File "/app/rephouse_backend/clickhouse/aggregations/queries/mentions.py" in fields_filter_values
84 31. 'prestart': self.prestart,
85
86Exception Type: AttributeError at /groups/2/candidates/
87Exception Value: 'CandidatesQuery' object has no attribute 'prestart'
88Request information:
89USER: 79170951655
90
91GET: No GET data
92
93POST: No POST data
94
95FILES: No FILES data
96
97COOKIES: No cookie data
98
99META:
100HTTP_ACCEPT = '*/*'
101HTTP_ACCEPT_ENCODING = 'gzip;q=1.0, compress;q=0.5'
102HTTP_ACCEPT_LANGUAGE = 'ru;q=1.0'
103HTTP_AUTHORIZATION = 'Token 386977a6754b80a58ecf210b12a208cda9962625'
104HTTP_CONNECTION = 'close'
105HTTP_HOST = '95.213.252.8'
106HTTP_USER_AGENT = 'Reputation house/3.3 (forafontov.Reputation-house; build:2; iOS 13.3.0) Alamofire/4.8.2'
107HTTP_X_FORWARDED_FOR = '188.65.246.53'
108PATH_INFO = '/groups/2/candidates/'
109QUERY_STRING = ''
110RAW_URI = '/groups/2/candidates/'
111REMOTE_ADDR = '172.22.0.9'
112REMOTE_PORT = '53938'
113REQUEST_METHOD = 'GET'
114SCRIPT_NAME = ''
115SERVER_NAME = '0.0.0.0'
116SERVER_PORT = '8000'
117SERVER_PROTOCOL = 'HTTP/1.0'
118SERVER_SOFTWARE = 'gunicorn/19.10.0'
119gunicorn.socket = <gevent._socket3.socket object, fd=11, family=2, type=1, proto=6>
120wsgi.errors = <gunicorn.http.wsgi.WSGIErrorsWrapper object at 0x7f7fa0842668>
121wsgi.file_wrapper = ''
122wsgi.input = <gunicorn.http.body.Body object at 0x7f7fa0558358>
123wsgi.input_terminated = True
124wsgi.multiprocess = True
125wsgi.multithread = True
126wsgi.run_once = False
127wsgi.url_scheme = 'http'
128wsgi.version = '(1, 0)'
129
130Settings:
131Using settings module rephouse_backend.settings
132ABSOLUTE_URL_OVERRIDES = {}
133ADMINS = []
134ADMIN_PASSWORD = '********************'
135ADMIN_USERNAME = 'mainAdmin2019'
136ALLOWED_HOSTS = ['95.213.252.8', '95.213.195.171', '95.213.252.8', '10.0.2.2', 'localhost']
137APPEND_SLASH = True
138AUTHENTICATION_BACKENDS = ['django.contrib.auth.backends.ModelBackend']
139AUTH_PASSWORD_VALIDATORS = '********************'
140AUTH_USER_MODEL = 'auth.User'
141BASE_DIR = '/app'
142CACHES = {'default': {'BACKEND': 'django.core.cache.backends.filebased.FileBasedCache', 'LOCATION': '/tmp/django_cache'}}
143CACHE_MIDDLEWARE_ALIAS = 'default'
144CACHE_MIDDLEWARE_KEY_PREFIX = '********************'
145CACHE_MIDDLEWARE_SECONDS = 600
146CELERYBEAT_SCHEDULER = 'django_celery_beat.schedulers.DatabaseScheduler'
147CELERY_BROKER_URL = 'amqp://guest:guest@rabbitmq:5672//'
148CELERY_IMPORTS = "('administration.tasks',)"
149CLICKHOUSE_DATABASE = 'default'
150CLICKHOUSE_HOST = 'http://clickhouse:8123'
151CLICKHOUSE_OLD_HOST = 'clickhouse'
152CORS_ALLOW_HEADERS = ['accept', 'accept-encoding', 'authorization', 'content-type', 'dnt', 'origin', 'user-agent', 'x-csrftoken', 'x-requested-with', 'content-disposition']
153CORS_ORIGIN_WHITELIST = ['http://95.213.252.8:8080', 'http://95.213.195.171:8080']
154CSRF_COOKIE_AGE = 31449600
155CSRF_COOKIE_DOMAIN = None
156CSRF_COOKIE_HTTPONLY = False
157CSRF_COOKIE_NAME = 'csrftoken'
158CSRF_COOKIE_PATH = '/'
159CSRF_COOKIE_SAMESITE = 'Lax'
160CSRF_COOKIE_SECURE = False
161CSRF_FAILURE_VIEW = 'django.views.csrf.csrf_failure'
162CSRF_HEADER_NAME = 'HTTP_X_CSRFTOKEN'
163CSRF_TRUSTED_ORIGINS = []
164CSRF_USE_SESSIONS = False
165DATABASES = {'default': {'ENGINE': 'django.db.backends.postgresql_psycopg2', 'NAME': 'rephouse', 'USER': 'rephouse', 'PASSWORD': '********************', 'HOST': 'postgres', 'PORT': 5432, 'ATOMIC_REQUESTS': False, 'AUTOCOMMIT': True, 'CONN_MAX_AGE': 0, 'OPTIONS': {}, 'TIME_ZONE': None, 'TEST': {'CHARSET': None, 'COLLATION': None, 'NAME': None, 'MIRROR': None}}}
166DATABASE_ROUTERS = []
167DATA_UPLOAD_MAX_MEMORY_SIZE = None
168DATA_UPLOAD_MAX_NUMBER_FIELDS = 1000
169DATETIME_FORMAT = 'N j, Y, P'
170DATETIME_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']
171DATE_FORMAT = 'N j, Y'
172DATE_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']
173DEBUG = True
174DEBUG_PROPAGATE_EXCEPTIONS = False
175DECIMAL_SEPARATOR = '.'
176DEFAULT_CHARSET = 'utf-8'
177DEFAULT_CONTENT_TYPE = 'text/html'
178DEFAULT_EXCEPTION_REPORTER_FILTER = 'django.views.debug.SafeExceptionReporterFilter'
179DEFAULT_FILE_STORAGE = 'django.core.files.storage.FileSystemStorage'
180DEFAULT_FROM_EMAIL = 'webmaster@localhost'
181DEFAULT_INDEX_TABLESPACE = ''
182DEFAULT_TABLESPACE = ''
183DEPLOY_TOKEN = '********************'
184DISALLOWED_USER_AGENTS = []
185EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend'
186EMAIL_HOST = 'smtp.yandex.ru'
187EMAIL_HOST_PASSWORD = '********************'
188EMAIL_HOST_USER = 'reputation.house'
189EMAIL_PORT = '465'
190EMAIL_SSL_CERTFILE = None
191EMAIL_SSL_KEYFILE = '********************'
192EMAIL_SUBJECT_PREFIX = '[Django] '
193EMAIL_TIMEOUT = None
194EMAIL_USE_LOCALTIME = False
195EMAIL_USE_SSL = True
196EMAIL_USE_TLS = False
197FILE_CHARSET = 'utf-8'
198FILE_UPLOAD_DIRECTORY_PERMISSIONS = None
199FILE_UPLOAD_HANDLERS = ['django.core.files.uploadhandler.MemoryFileUploadHandler', 'django.core.files.uploadhandler.TemporaryFileUploadHandler']
200FILE_UPLOAD_MAX_MEMORY_SIZE = 2621440
201FILE_UPLOAD_PERMISSIONS = None
202FILE_UPLOAD_TEMP_DIR = None
203FIRST_DAY_OF_WEEK = 0
204FIXTURE_DIRS = []
205FORCE_SCRIPT_NAME = None
206FORMAT_MODULE_PATH = None
207FORM_RENDERER = 'django.forms.renderers.DjangoTemplates'
208IGNORABLE_404_URLS = []
209INSTALLED_APPS = ['django.contrib.auth', 'django.contrib.contenttypes', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', 'django.contrib.admin', 'drf_yasg', 'rest_framework.authtoken', 'corsheaders', 'colorful', 'push_notifications', 'django_celery_beat', 'authorization', 'mentions', 'administration', 'app']
210INTERNAL_IPS = []
211LANGUAGES = [('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'), ('hy', 'Armenian'), ('ia', 'Interlingua'), ('id', 'Indonesian'), ('io', 'Ido'), ('is', 'Icelandic'), ('it', 'Italian'), ('ja', 'Japanese'), ('ka', 'Georgian'), ('kab', 'Kabyle'), ('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')]
212LANGUAGES_BIDI = ['he', 'ar', 'fa', 'ur']
213LANGUAGE_CODE = 'en-us'
214LANGUAGE_COOKIE_AGE = None
215LANGUAGE_COOKIE_DOMAIN = None
216LANGUAGE_COOKIE_NAME = 'django_language'
217LANGUAGE_COOKIE_PATH = '/'
218LOCALE_PATHS = []
219LOGGING = {}
220LOGGING_CONFIG = 'logging.config.dictConfig'
221LOGIN_REDIRECT_URL = '/accounts/profile/'
222LOGIN_URL = '/accounts/login/'
223LOGOUT_REDIRECT_URL = None
224MANAGERS = []
225MEDIA_ROOT = '/app/media/'
226MEDIA_URL = '/media/'
227MENTIONS_CACHE_TIME = 3600
228MESSAGE_STORAGE = 'django.contrib.messages.storage.fallback.FallbackStorage'
229MIDDLEWARE = ['django.middleware.security.SecurityMiddleware', 'django.contrib.sessions.middleware.SessionMiddleware', 'corsheaders.middleware.CorsMiddleware', 'django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware', 'django.contrib.auth.middleware.AuthenticationMiddleware', 'django.contrib.messages.middleware.MessageMiddleware', 'django.middleware.clickjacking.XFrameOptionsMiddleware']
230MIGRATION_MODULES = {}
231MONTH_DAY_FORMAT = 'F j'
232NUMBER_GROUPING = 0
233PASSWORD_HASHERS = '********************'
234PASSWORD_RESET_TIMEOUT_DAYS = '********************'
235PREPEND_WWW = False
236PUSH_NOTIFICATIONS_SETTINGS = {'FCM_API_KEY': '********************', 'CONFIG': 'push_notifications.conf.LegacyConfig', 'GCM_POST_URL': 'https://android.googleapis.com/gcm/send', 'GCM_MAX_RECIPIENTS': 1000, 'GCM_ERROR_TIMEOUT': None, 'FCM_POST_URL': 'https://fcm.googleapis.com/fcm/send', 'FCM_MAX_RECIPIENTS': 1000, 'FCM_ERROR_TIMEOUT': None, 'APNS_USE_SANDBOX': True, 'APNS_USE_ALTERNATIVE_PORT': False, 'APNS_TOPIC': None, 'WNS_PACKAGE_SECURITY_ID': None, 'WNS_SECRET_KEY': '********************', 'WNS_ACCESS_URL': 'https://login.live.com/accesstoken.srf', 'WP_POST_URL': {'CHROME': 'https://fcm.googleapis.com/fcm/send', 'OPERA': 'https://fcm.googleapis.com/fcm/send', 'FIREFOX': 'https://updates.push.services.mozilla.com/wpush/v2'}, 'WP_PRIVATE_KEY': '********************', 'WP_CLAIMS': None, 'WP_ERROR_TIMEOUT': None, 'USER_MODEL': 'auth.User', 'UPDATE_ON_DUPLICATE_REG_ID': False}
237REPORT_TARGET_EMAIL = 'forafontov98@gmail.com'
238REST_FRAMEWORK = {'DEFAULT_PAGINATION_CLASS': 'mentions.paginators.FastPageNumberPagination', 'PAGE_SIZE': 25}
239ROOT_URLCONF = 'rephouse_backend.urls'
240SECRET_KEY = '********************'
241SECURE_BROWSER_XSS_FILTER = False
242SECURE_CONTENT_TYPE_NOSNIFF = False
243SECURE_HSTS_INCLUDE_SUBDOMAINS = False
244SECURE_HSTS_PRELOAD = False
245SECURE_HSTS_SECONDS = 0
246SECURE_PROXY_SSL_HEADER = None
247SECURE_REDIRECT_EXEMPT = []
248SECURE_SSL_HOST = None
249SECURE_SSL_REDIRECT = False
250SERVER_EMAIL = 'root@localhost'
251SESSION_CACHE_ALIAS = 'default'
252SESSION_COOKIE_AGE = 1209600
253SESSION_COOKIE_DOMAIN = None
254SESSION_COOKIE_HTTPONLY = True
255SESSION_COOKIE_NAME = 'sessionid'
256SESSION_COOKIE_PATH = '/'
257SESSION_COOKIE_SAMESITE = 'Lax'
258SESSION_COOKIE_SECURE = False
259SESSION_ENGINE = 'django.contrib.sessions.backends.db'
260SESSION_EXPIRE_AT_BROWSER_CLOSE = False
261SESSION_FILE_PATH = None
262SESSION_SAVE_EVERY_REQUEST = False
263SESSION_SERIALIZER = 'django.contrib.sessions.serializers.JSONSerializer'
264SETTINGS_MODULE = 'rephouse_backend.settings'
265SHORT_DATETIME_FORMAT = 'm/d/Y P'
266SHORT_DATE_FORMAT = 'm/d/Y'
267SIGNING_BACKEND = 'django.core.signing.TimestampSigner'
268SILENCED_SYSTEM_CHECKS = []
269SMS_CODE_TIMEOUT = 600
270STATICFILES_DIRS = ['/app/rephouse_backend/static/']
271STATICFILES_FINDERS = ['django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder']
272STATICFILES_STORAGE = 'django.contrib.staticfiles.storage.StaticFilesStorage'
273STATIC_ROOT = '/app/static/'
274STATIC_URL = '/static/'
275SWAGGER_SETTINGS = {'DEFAULT_AUTO_SCHEMA_CLASS': 'rephouse_backend.swagger.ErrorResponseAutoSchema', 'SECURITY_DEFINITIONS': {'Token': '********************'}}
276TEMPLATES = [{'BACKEND': 'django.template.backends.django.DjangoTemplates', 'DIRS': ['/app/rephouse_backend/templates'], 'APP_DIRS': True, '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']}}]
277TEST_NON_SERIALIZED_APPS = []
278TEST_RUNNER = 'django.test.runner.DiscoverRunner'
279THOUSAND_SEPARATOR = ','
280TIME_FORMAT = 'P'
281TIME_INPUT_FORMATS = ['%H:%M:%S', '%H:%M:%S.%f', '%H:%M']
282TIME_ZONE = 'UTC'
283TWILIO_ACCOUNT_SID = 'ACec702ed7b7799dc5eb6212b6ca973ec8'
284TWILIO_AUTH_TOKEN = '********************'
285TWILIO_SENDER = '+14155211538'
286USE_I18N = True
287USE_L10N = True
288USE_THOUSAND_SEPARATOR = False
289USE_TZ = True
290USE_X_FORWARDED_HOST = False
291USE_X_FORWARDED_PORT = False
292WSGI_APPLICATION = 'rephouse_backend.wsgi.application'
293X_FRAME_OPTIONS = 'SAMEORIGIN'
294YEAR_MONTH_FORMAT = 'F Y'
295
296
297You're seeing this error because you have DEBUG = True in your
298Django settings file. Change that to False, and Django will
299display a standard page generated by the handler for this status code.