cortex-lab / alyx-matlab

Some MATLAB functions for easier interfacing with an Alyx database
3 stars 2 forks source link

Certain mice -can't open subject history in GUI #29

Closed laurax452 closed 6 years ago

laurax452 commented 7 years ago

There are a small number of Armin's mice that refuse to open their subject history (ALK044, ALK051 and maybe ALK057?) on the GUI. Do you know what is causing this? Most of his other mice open up fine and all of the other mice I train for others are fine too. Small glitch...? The information is on Alyx and when the new subject history is live on alyx then I can use that, but I've no idea why these mice aren't displaying properly. The rest of the GUI is fine, in terms of displaying and logging water requirements. BW Laura

nsteinme commented 7 years ago

Error message?

On Wed, Aug 30, 2017 at 10:07 AM, laurax452 notifications@github.com wrote:

There are a small number of Armin's mice that refuse to open their subject history (ALK044, ALK051 and maybe ALK057?) on the GUI. Do you know what is causing this? Most of his other mice open up fine and all of the other mice I train for others are fine too. Small glitch...? The information is on Alyx and when the new subject history is live on alyx then I can use that, but I've no idea why these mice aren't displaying properly. The rest of the GUI is fine, in terms of displaying and logging water requirements. BW Laura

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/cortex-lab/alyx-matlab/issues/29, or mute the thread https://github.com/notifications/unsubscribe-auth/AHPUP9KzhH3KW1m6-Gygy6W9VfJSzw6Lks5sdSY9gaJpZM4PHFSN .

laurax452 commented 7 years ago

None, just doesnt open...


From: Nick Steinmetz notifications@github.com Sent: 30 August 2017 10:17:04 To: cortex-lab/alyx-matlab Cc: Funnell, Laura; Author Subject: Re: [cortex-lab/alyx-matlab] Certain mice -can't open subject history in GUI (#29)

Error message?

On Wed, Aug 30, 2017 at 10:07 AM, laurax452 notifications@github.com wrote:

There are a small number of Armin's mice that refuse to open their subject history (ALK044, ALK051 and maybe ALK057?) on the GUI. Do you know what is causing this? Most of his other mice open up fine and all of the other mice I train for others are fine too. Small glitch...? The information is on Alyx and when the new subject history is live on alyx then I can use that, but I've no idea why these mice aren't displaying properly. The rest of the GUI is fine, in terms of displaying and logging water requirements. BW Laura

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/cortex-lab/alyx-matlab/issues/29, or mute the thread https://github.com/notifications/unsubscribe-auth/AHPUP9KzhH3KW1m6-Gygy6W9VfJSzw6Lks5sdSY9gaJpZM4PHFSN .

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/cortex-lab/alyx-matlab/issues/29#issuecomment-325933254, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AaqdSWvakYFiM-PA3lVQzkRF_OwpFauiks5sdSiQgaJpZM4PHFSN.

laurax452 commented 7 years ago

None

k1o0 commented 7 years ago

I believe there is an error message associated with this:

`Error using alyx.getData (line 16) TypeError at /water-requirement/PC012 unsupported operand type(s) for +=: 'float' and 'NoneType'

Request Method: GET Request URL: https://alyx.cortexlab.net/water-requirement/PC012?start_date=2016-01-01&end_date=2017-08-30 Django Version: 1.11 Python Executable: /var/www/alyx/alyx/bin/python Python Version: 3.5.2 Python Path: ['/var/www/alyx/alyx', '/var/www/alyx/alyx/lib/python35.zip', '/var/www/alyx/alyx/lib/python3.5', '/var/www/alyx/alyx/lib/python3.5/plat-x86_64-linux-gnu', '/var/www/alyx/alyx/lib/python3.5/lib-dynload', '/usr/lib/python3.5', '/usr/lib/python3.5/plat-x86_64-linux-gnu', '/var/www/alyx/alyx/lib/python3.5/site-packages'] Server time: Wed, 30 Aug 2017 15:21:15 +0100 Installed Applications: ('test_without_migrations', 'dal', 'dal_select2', 'reversion', 'django_admin_listfilter_dropdown', 'subjects', 'django_filters', 'django.contrib.admin', 'django.contrib.contenttypes', 'django.contrib.auth', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', 'polymorphic', 'rest_framework', 'rest_framework.authtoken', 'equipment', 'actions', 'data', 'misc', 'behavior', 'electrophysiology', 'imaging') Installed 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')

Traceback:

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/core/handlers/exception.py" in inner

  1. response = get_response(request)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/core/handlers/base.py" in _get_response

  1. response = self.process_exception_by_middleware(e, request)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/core/handlers/base.py" in _get_response

  1. response = wrapped_callback(request, *callback_args, **callback_kwargs)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/views/decorators/csrf.py" in wrapped_view

  1. return view_func(*args, **kwargs)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/views/generic/base.py" in view

  1. return self.dispatch(request, *args, **kwargs)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/rest_framework/views.py" in dispatch

  1. response = self.handle_exception(exc)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/rest_framework/views.py" in handle_exception

  1. self.raise_uncaught_exception(exc)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/rest_framework/views.py" in dispatch

  1. response = handler(request, *args, **kwargs)

File "/var/www/alyx/alyx/actions/views.py" in get

  1. was_out[date][name] += wa['administered']

Exception Type: TypeError at /water-requirement/PC012 Exception Value: unsupported operand type(s) for +=: 'float' and 'NoneType' Request information: USER: miles

GET: start_date = '2016-01-01' end_date = '2017-08-30'

POST: No POST data

FILES: No FILES data

COOKIES: No cookie data

META: CONTEXT_DOCUMENT_ROOT = '/var/www/html' CONTEXT_PREFIX = '' DOCUMENT_ROOT = '/var/www/html' GATEWAY_INTERFACE = 'CGI/1.1' HTTP_ACCEPT = 'application/json; charset=UTF-8' HTTP_ACCEPT_ENCODING = 'gzip,deflate' HTTP_AUTHORIZATION = 'Token 209351c2514305cc6238f27d4fea4086cfe8cb2b' HTTP_CONNECTION = 'Keep-Alive' HTTP_HOST = 'alyx.cortexlab.net' HTTP_USER_AGENT = 'Apache-HttpClient/4.3.6 (java 1.5)' PATH_INFO = '/water-requirement/PC012' PATH_TRANSLATED = '/var/www/alyx/alyx/alyx/wsgi.py/water-requirement/PC012' QUERY_STRING = 'start_date=2016-01-01&end_date=2017-08-30' REMOTE_ADDR = '128.40.198.170' REMOTE_PORT = '49934' REQUEST_METHOD = 'GET' REQUEST_SCHEME = 'https' REQUEST_URI = '/water-requirement/PC012?start_date=2016-01-01&end_date=2017-08-30' SCRIPT_FILENAME = '/var/www/alyx/alyx/alyx/wsgi.py' SCRIPT_NAME = '' SERVER_ADDR = '172.31.29.62' SERVER_ADMIN = 'webmaster@cortexlab.net' SERVER_NAME = 'alyx.cortexlab.net' SERVER_PORT = '443' SERVER_PROTOCOL = 'HTTP/1.1' SERVER_SIGNATURE = '

Apache/2.4.18 (Ubuntu) Server at alyx.cortexlab.net Port 443
\n' SERVER_SOFTWARE = 'Apache/2.4.18 (Ubuntu)' SSL_TLS_SNI = 'alyx.cortexlab.net' apache.version = mod_wsgi.application_group = 'alyx.cortexlab.net|' mod_wsgi.callable_object = 'application' mod_wsgi.daemon_connects = '1' mod_wsgi.daemon_restarts = '0' mod_wsgi.daemon_start = '1504102875196737' mod_wsgi.enable_sendfile = '0' mod_wsgi.handler_script = '' mod_wsgi.input_chunked = '0' mod_wsgi.listener_host = '' mod_wsgi.listener_port = '443' mod_wsgi.process_group = 'alyx' mod_wsgi.queue_start = '1504102875196622' mod_wsgi.request_handler = 'wsgi-script' mod_wsgi.request_start = '1504102875196511' mod_wsgi.script_reloading = '1' mod_wsgi.script_start = '1504102875196814' mod_wsgi.version = wsgi.errors = <_io.TextIOWrapper encoding='utf-8'> wsgi.file_wrapper = '' wsgi.input = <mod_wsgi.Input object at 0x7fafe6f62c30> wsgi.multiprocess = False wsgi.multithread = True wsgi.run_once = False wsgi.url_scheme = 'https' wsgi.version =

Settings: Using settings module alyx.settings ABSOLUTE_URL_OVERRIDES = {} ADMINS = [] ALLOWED_HOSTS = ['localhost', 'alyx-dev.cortexlab.net', 'alyx.cortexlab.net'] APPEND_SLASH = True AUTHENTICATION_BACKENDS = ['django.contrib.auth.backends.ModelBackend'] AUTH_PASSWORD_VALIDATORS = '****' AUTH_USER_MODEL = 'auth.User' BASE_DIR = '/var/www/alyx/alyx' CACHES = {'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache'}} CACHE_MIDDLEWARE_ALIAS = 'default' CACHE_MIDDLEWARE_KEY_PREFIX = '****' CACHE_MIDDLEWARE_SECONDS = 600 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 = [] CSRF_USE_SESSIONS = False DATABASES = {'default': {'ATOMIC_REQUESTS': False, 'OPTIONS': {}, 'TIME_ZONE': None, 'USER': 'alyx', 'NAME': 'alyx', 'TEST': {'MIRROR': None, 'COLLATION': None, 'CHARSET': None, 'NAME': None}, 'HOST': '127.0.0.1', 'PASSWORD': '****', 'AUTOCOMMIT': True, 'PORT': '5432', 'ENGINE': 'django.db.backends.postgresql_psycopg2', 'CONN_MAX_AGE': 0}} DATABASE_ROUTERS = [] DATA_UPLOAD_MAX_MEMORY_SIZE = 2621440 DATA_UPLOAD_MAX_NUMBER_FIELDS = 10000 DATETIME_FORMAT = 'N j, Y, P' 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'] DATE_FORMAT = 'N j, Y' DATE_INPUT_FORMATS = '%d/%m/%Y' DEBUG = True DEBUG_PROPAGATE_EXCEPTIONS = False DECIMAL_SEPARATOR = '.' DEFAULT_CHARSET = 'utf-8' DEFAULT_CONTENT_TYPE = 'text/html' DEFAULT_EXCEPTION_REPORTER_FILTER = 'django.views.debug.SafeExceptionReporterFilter' DEFAULT_FILE_STORAGE = 'django.core.files.storage.FileSystemStorage' DEFAULT_FROM_EMAIL = 'webmaster@localhost' DEFAULT_INDEX_TABLESPACE = '' DEFAULT_PROTOCOL = '1' DEFAULT_SOURCE = 'Cruciform BSU' DEFAULT_TABLESPACE = '' DISALLOWED_USER_AGENTS = [] EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend' EMAIL_HOST = 'smtp.gmail.com' EMAIL_HOST_PASSWORD = '****' EMAIL_HOST_USER = 'alyxdb' EMAIL_PORT = 587 EMAIL_SSL_CERTFILE = None EMAIL_SSL_KEYFILE = '****' EMAIL_SUBJECT_PREFIX = '[Django] ' EMAIL_TIMEOUT = None EMAIL_USE_LOCALTIME = False EMAIL_USE_SSL = False EMAIL_USE_TLS = True 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 FORM_RENDERER = 'django.forms.renderers.DjangoTemplates' IGNORABLE_404_URLS = [] INSTALLED_APPS = INTERNAL_IPS = [] 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 = 'en-us' LANGUAGE_COOKIE_AGE = None LANGUAGE_COOKIE_DOMAIN = None LANGUAGE_COOKIE_NAME = 'django_language' LANGUAGE_COOKIE_PATH = '/' LOCALE_PATHS = [] LOGGING = {'formatters': {'simple': {'format': '%(log_color)s%(asctime)s [%(levelname)s] %(message)s', 'datefmt': '%d/%m %H:%M:%S', '()': 'colorlog.ColoredFormatter', 'log_colors': {'WARNING': 'yellow', 'CRITICAL': 'bold_red', 'INFO': 'white', 'DEBUG': 'cyan', 'ERROR': 'red'}}}, 'handlers': {'console': {'level': 'DEBUG', 'formatter': 'simple', 'class': 'logging.StreamHandler'}, 'file': {'level': 'DEBUG', 'formatter': 'simple', 'maxBytes': 16777216, 'filename': '/var/log/alyx.log', 'class': 'logging.handlers.RotatingFileHandler'}}, 'loggers': {'django': {'level': 'INFO', 'handlers': ['file'], 'propagate': True}}, 'version': 1, 'disable_existing_loggers': False, 'root': {'level': 'DEBUG', 'handlers': ['file', 'console'], 'propagate': True}} LOGGING_CONFIG = 'logging.config.dictConfig' LOGIN_REDIRECT_URL = '/accounts/profile/' LOGIN_URL = '/accounts/login/' LOGOUT_REDIRECT_URL = None MANAGERS = [] MEDIA_ROOT = '' MEDIA_URL = '' MESSAGE_STORAGE = 'django.contrib.messages.storage.fallback.FallbackStorage' MIDDLEWARE = MIDDLEWARE_CLASSES = ['django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware'] MIGRATION_MODULES = {} MONTH_DAY_FORMAT = 'F j' NUMBER_GROUPING = 0 PASSWORD_HASHERS = '****' PASSWORD_RESET_TIMEOUT_DAYS = '****' PREPEND_WWW = False REST_FRAMEWORK = {'DEFAULT_FILTER_BACKENDS': ('django_filters.rest_framework.DjangoFilterBackend',), 'DEFAULT_AUTHENTICATION_CLASSES': ('rest_framework.authentication.SessionAuthentication', 'rest_framework.authentication.TokenAuthentication')} ROOT_URLCONF = 'alyx.urls' SECRET_KEY = '****' SECURE_BROWSER_XSS_FILTER = False SECURE_CONTENT_TYPE_NOSNIFF = False SECURE_HSTS_INCLUDE_SUBDOMAINS = False SECURE_HSTS_PRELOAD = 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 = 'alyx.settings' SHORT_DATETIME_FORMAT = 'm/d/Y P' SHORT_DATE_FORMAT = 'm/d/Y' SIGNING_BACKEND = 'django.core.signing.TimestampSigner' SILENCED_SYSTEM_CHECKS = [] STATICFILES_DIRS = [] STATICFILES_FINDERS = ['django.contrib.staticfiles.finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder'] STATICFILES_STORAGE = 'django.contrib.staticfiles.storage.StaticFilesStorage' STATIC_ROOT = '/var/www/alyx/alyx/static/' STATIC_URL = '/static/' STOCK_MANAGERS = 'charu' SUBJECT_REQUEST_EMAIL_FROM = 'alyx-noreply@cortexlab.net' SUPERUSERS = TEMPLATES = [{'BACKEND': 'django.template.backends.django.DjangoTemplates', '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']}, 'APP_DIRS': True, 'DIRS': ['/var/www/alyx/alyx/templates']}] TEST_NON_SERIALIZED_APPS = [] TEST_RUNNER = 'django.test.runner.DiscoverRunner' THOUSAND_SEPARATOR = ',' TIME_FORMAT = 'P' TIME_INPUT_FORMATS = ['%H:%M:%S', '%H:%M:%S.%f', '%H:%M'] TIME_ZONE = 'GB' USE_ETAGS = False USE_I18N = False USE_L10N = False USE_THOUSAND_SEPARATOR = False USE_TZ = True USE_X_FORWARDED_HOST = False USE_X_FORWARDED_PORT = False WSGI_APPLICATION = 'alyx.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.

Error in eui.AlyxPanel/viewSubjectHistory (line 364) wr = alyx.getData(ai, endpnt);

Error in eui.AlyxPanel>@(src,evt)viewSubjectHistory(obj) (line 41) 'Callback', @(src, evt)viewSubjectHistory(obj));

Error while evaluating UIControl Callback `

nsteinme commented 7 years ago

Great, please post this error to alyx github -

On Wed, Aug 30, 2017 at 6:56 PM, k1o0 notifications@github.com wrote:

I believe there is an error message associated with this:

`Error using alyx.getData (line 16) TypeError at /water-requirement/PC012 unsupported operand type(s) for +=: 'float' and 'NoneType'

Request Method: GET Request URL: https://alyx.cortexlab.net/water-requirement/PC012?start_ date=2016-01-01&end_date=2017-08-30 Django Version: 1.11 Python Executable: /var/www/alyx/alyx/bin/python Python Version: 3.5.2 Python Path: ['/var/www/alyx/alyx', '/var/www/alyx/alyx/lib/python35.zip', '/var/www/alyx/alyx/lib/python3.5', '/var/www/alyx/alyx/lib/python3.5/plat-x86_64-linux-gnu', '/var/www/alyx/alyx/lib/python3.5/lib-dynload', '/usr/lib/python3.5', '/usr/lib/python3.5/plat-x86_64-linux-gnu', '/var/www/alyx/alyx/lib/python3.5/site-packages'] Server time: Wed, 30 Aug 2017 15:21:15 +0100 Installed Applications: ('test_without_migrations', 'dal', 'dal_select2', 'reversion', 'django_admin_listfilter_dropdown', 'subjects', 'django_filters', 'django.contrib.admin', 'django.contrib.contenttypes', 'django.contrib.auth', 'django.contrib.sessions', 'django.contrib.messages', 'django.contrib.staticfiles', 'polymorphic', 'rest_framework', 'rest_framework.authtoken', 'equipment', 'actions', 'data', 'misc', 'behavior', 'electrophysiology', 'imaging') Installed 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')

Traceback:

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/core/handlers/exception.py" in inner

  1. response = get_response(request)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/core/handlers/base.py" in _get_response

  1. response = self.process_exception_by_middleware(e, request)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/core/handlers/base.py" in _get_response

  1. response = wrapped_callback(request, *callback_args, **callback_kwargs)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/ django/views/decorators/csrf.py" in wrapped_view

  1. return view_func(*args, **kwargs)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/django/views/generic/base.py" in view

  1. return self.dispatch(request, *args, **kwargs)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/rest_framework/views.py" in dispatch

  1. response = self.handle_exception(exc)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/rest_framework/views.py" in handle_exception

  1. self.raise_uncaught_exception(exc)

File "/var/www/alyx/alyx/lib/python3.5/site-packages/rest_framework/views.py" in dispatch

  1. response = handler(request, *args, **kwargs)

File "/var/www/alyx/alyx/actions/views.py" in get

  1. was_out[date][name] += wa['administered']

Exception Type: TypeError at /water-requirement/PC012 Exception Value: unsupported operand type(s) for +=: 'float' and 'NoneType' Request information: USER: miles

GET: start_date = '2016-01-01' end_date = '2017-08-30'

POST: No POST data

FILES: No FILES data

COOKIES: No cookie data

META: CONTEXT_DOCUMENT_ROOT = '/var/www/html' CONTEXT_PREFIX = '' DOCUMENT_ROOT = '/var/www/html' GATEWAY_INTERFACE = 'CGI/1.1' HTTP_ACCEPT = 'application/json; charset=UTF-8' HTTP_ACCEPT_ENCODING = 'gzip,deflate' HTTP_AUTHORIZATION = 'Token 209351c2514305cc6238f27d4fea4086cfe8cb2b' HTTP_CONNECTION = 'Keep-Alive' HTTP_HOST = 'alyx.cortexlab.net' HTTP_USER_AGENT = 'Apache-HttpClient/4.3.6 (java 1.5)' PATH_INFO = '/water-requirement/PC012' PATH_TRANSLATED = '/var/www/alyx/alyx/alyx/wsgi.py/water-requirement/PC012 ' QUERY_STRING = 'start_date=2016-01-01&end_date=2017-08-30' REMOTE_ADDR = '128.40.198.170' REMOTE_PORT = '49934' REQUEST_METHOD = 'GET' REQUEST_SCHEME = 'https' REQUEST_URI = '/water-requirement/PC012?startdate=2016-01-01&end date=2017-08-30' SCRIPT_FILENAME = '/var/www/alyx/alyx/alyx/wsgi.py' SCRIPT_NAME = '' SERVER_ADDR = '172.31.29.62' SERVER_ADMIN = 'webmaster@cortexlab.net' SERVER_NAME = 'alyx.cortexlab.net' SERVER_PORT = '443' SERVER_PROTOCOL = 'HTTP/1.1' SERVER_SIGNATURE = ' Apache/2.4.18 (Ubuntu) Server at alyx.cortexlab.net Port 443\n' SERVER_SOFTWARE = 'Apache/2.4.18 (Ubuntu)' SSL_TLS_SNI = 'alyx.cortexlab.net' apache.version = mod_wsgi.application_group = 'alyx.cortexlab.net|' mod_wsgi.callable_object = 'application' mod_wsgi.daemon_connects = '1' mod_wsgi.daemon_restarts = '0' mod_wsgi.daemon_start = '1504102875196737' mod_wsgi.enable_sendfile = '0' mod_wsgi.handler_script = '' mod_wsgi.input_chunked = '0' mod_wsgi.listener_host = '' mod_wsgi.listener_port = '443' mod_wsgi.process_group = 'alyx' mod_wsgi.queue_start = '1504102875196622' mod_wsgi.request_handler = 'wsgi-script' mod_wsgi.request_start = '1504102875196511' mod_wsgi.script_reloading = '1' mod_wsgi.script_start = '1504102875196814' mod_wsgi.version = wsgi.errors = <_io.TextIOWrapper encoding='utf-8'> wsgi.file_wrapper = '' wsgi.input = <mod_wsgi.Input object at 0x7fafe6f62c30> wsgi.multiprocess = False wsgi.multithread = True wsgi.run_once = False wsgi.url_scheme = 'https' wsgi.version =

Settings: Using settings module alyx.settings ABSOLUTE_URL_OVERRIDES = {} ADMINS = [] ALLOWED_HOSTS = ['localhost', 'alyx-dev.cortexlab.net', ' alyx.cortexlab.net'] APPEND_SLASH = True AUTHENTICATION_BACKENDS = ['django.contrib.auth.backends.ModelBackend'] AUTH_PASSWORD_VALIDATORS = '

' AUTH_USER_MODEL = 'auth.User' BASE_DIR = '/var/www/alyx/alyx' CACHES = {'default': {'BACKEND': 'django.core.cache.backends.locmem.LocMemCache'}} CACHE_MIDDLEWARE_ALIAS = 'default' CACHE_MIDDLEWARE_KEY_PREFIX = '' CACHE_MIDDLEWARE_SECONDS = 600 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 = [] CSRF_USE_SESSIONS = False DATABASES = {'default': {'ATOMIC_REQUESTS': False, 'OPTIONS': {}, 'TIME_ZONE': None, 'USER': 'alyx', 'NAME': 'alyx', 'TEST': {'MIRROR': None, 'COLLATION': None, 'CHARSET': None, 'NAME': None}, 'HOST': '127.0.0.1', 'PASSWORD': '

', 'AUTOCOMMIT': True, 'PORT': '5432', 'ENGINE': 'django.db.backends.postgresql_psycopg2', 'CONN_MAX_AGE': 0}} DATABASE_ROUTERS = [] DATA_UPLOAD_MAX_MEMORY_SIZE = 2621440 DATA_UPLOAD_MAX_NUMBER_FIELDS = 10000 DATETIME_FORMAT = 'N j, Y, P' 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'] DATE_FORMAT = 'N j, Y' DATE_INPUT_FORMATS = '%d/%m/%Y' DEBUG = True DEBUG_PROPAGATE_EXCEPTIONS = False DECIMAL_SEPARATOR = '.' DEFAULT_CHARSET = 'utf-8' DEFAULT_CONTENT_TYPE = 'text/html' DEFAULT_EXCEPTION_REPORTER_FILTER = 'django.views.debug.SafeExceptionReporterFilter' DEFAULT_FILE_STORAGE = 'django.core.files.storage.FileSystemStorage' DEFAULT_FROM_EMAIL = 'webmaster@localhost' DEFAULT_INDEX_TABLESPACE = '' DEFAULT_PROTOCOL = '1' DEFAULT_SOURCE = 'Cruciform BSU' DEFAULT_TABLESPACE = '' DISALLOWED_USER_AGENTS = [] EMAIL_BACKEND = 'django.core.mail.backends.smtp.EmailBackend' EMAIL_HOST = 'smtp.gmail.com http://smtp.gmail.com' EMAIL_HOST_PASSWORD = '' EMAIL_HOST_USER = 'alyxdb' EMAIL_PORT = 587 EMAIL_SSL_CERTFILE = None EMAIL_SSL_KEYFILE = '

' EMAIL_SUBJECT_PREFIX = '[Django] ' EMAIL_TIMEOUT = None EMAIL_USE_LOCALTIME = False EMAIL_USE_SSL = False EMAIL_USE_TLS = True 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 FORM_RENDERER = 'django.forms.renderers.DjangoTemplates' IGNORABLE_404_URLS = [] INSTALLED_APPS = INTERNAL_IPS = [] 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 = 'en-us' LANGUAGE_COOKIE_AGE = None LANGUAGE_COOKIE_DOMAIN = None LANGUAGE_COOKIE_NAME = 'django_language' LANGUAGE_COOKIE_PATH = '/' LOCALE_PATHS = [] LOGGING = {'formatters': {'simple': {'format': '%(log_color)s%(asctime)s [%(levelname)s] %(message)s', 'datefmt': '%d/%m %H:%M:%S', '()': 'colorlog.ColoredFormatter', 'log_colors': {'WARNING': 'yellow', 'CRITICAL': 'bold_red', 'INFO': 'white', 'DEBUG': 'cyan', 'ERROR': 'red'}}}, 'handlers': {'console': {'level': 'DEBUG', 'formatter': 'simple', 'class': 'logging.StreamHandler'}, 'file': {'level': 'DEBUG', 'formatter': 'simple', 'maxBytes': 16777216, 'filename': '/var/log/alyx.log', 'class': 'logging.handlers.RotatingFileHandler'}}, 'loggers': {'django': {'level': 'INFO', 'handlers': ['file'], 'propagate': True}}, 'version': 1, 'disable_existing_loggers': False, 'root': {'level': 'DEBUG', 'handlers': ['file', 'console'], 'propagate': True}} LOGGING_CONFIG = 'logging.config.dictConfig' LOGIN_REDIRECT_URL = '/accounts/profile/' LOGIN_URL = '/accounts/login/' LOGOUT_REDIRECT_URL = None MANAGERS = [] MEDIA_ROOT = '' MEDIA_URL = '' MESSAGE_STORAGE = 'django.contrib.messages.storage.fallback.FallbackStorage' MIDDLEWARE = MIDDLEWARE_CLASSES = ['django.middleware.common.CommonMiddleware', 'django.middleware.csrf.CsrfViewMiddleware'] MIGRATION_MODULES = {} MONTH_DAY_FORMAT = 'F j' NUMBER_GROUPING = 0 PASSWORD_HASHERS = '' PASSWORD_RESET_TIMEOUT_DAYS = '

' PREPEND_WWW = False REST_FRAMEWORK = {'DEFAULT_FILTER_BACKENDS': ('django_filters.rest_framework.DjangoFilterBackend',), 'DEFAULT_AUTHENTICATION_CLASSES': ('rest_framework.authentication.SessionAuthentication', 'rest_framework.authentication.TokenAuthentication')} ROOT_URLCONF = 'alyx.urls' SECRET_KEY = '' SECURE_BROWSER_XSS_FILTER = False SECURE_CONTENT_TYPE_NOSNIFF = False SECURE_HSTS_INCLUDE_SUBDOMAINS = False SECURE_HSTS_PRELOAD = 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 = 'alyx.settings' SHORT_DATETIME_FORMAT = 'm/d/Y P' SHORT_DATE_FORMAT = 'm/d/Y' SIGNING_BACKEND = 'django.core.signing.TimestampSigner' SILENCED_SYSTEM_CHECKS = [] STATICFILES_DIRS = [] STATICFILES_FINDERS = ['django.contrib.staticfiles. finders.FileSystemFinder', 'django.contrib.staticfiles.finders.AppDirectoriesFinder'] STATICFILES_STORAGE = 'django.contrib.staticfiles. storage.StaticFilesStorage' STATIC_ROOT = '/var/www/alyx/alyx/static/' STATIC_URL = '/static/' STOCK_MANAGERS = 'charu' SUBJECT_REQUEST_EMAIL_FROM = 'alyx-noreply@cortexlab.net' SUPERUSERS = TEMPLATES = [{'BACKEND': 'django.template.backends.django.DjangoTemplates', 'OPTIONS': {'context_processors': ['django.template.contextprocessors.debug', 'django.template.context processors.request', 'django.contrib.auth.context_processors.auth', 'django.contrib.messages. context_processors.messages']}, 'APP_DIRS': True, 'DIRS': ['/var/www/alyx/alyx/templates']}] TEST_NON_SERIALIZED_APPS = [] TEST_RUNNER = 'django.test.runner.DiscoverRunner' THOUSAND_SEPARATOR = ',' TIME_FORMAT = 'P' TIME_INPUT_FORMATS = ['%H:%M:%S', '%H:%M:%S.%f', '%H:%M'] TIME_ZONE = 'GB' USE_ETAGS = False USE_I18N = False USE_L10N = False USE_THOUSAND_SEPARATOR = False USE_TZ = True USE_X_FORWARDED_HOST = False USE_X_FORWARDED_PORT = False WSGI_APPLICATION = 'alyx.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.

Error in eui.AlyxPanel/viewSubjectHistory (line 364) wr = alyx.getData(ai, endpnt);

Error in eui.AlyxPanel>@(src,evt)viewSubjectHistory(obj) (line 41) 'Callback', @(src, evt)viewSubjectHistory(obj));

Error while evaluating UIControl Callback `

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/cortex-lab/alyx-matlab/issues/29#issuecomment-326069897, or mute the thread https://github.com/notifications/unsubscribe-auth/AHPUP96Q2UtBGBmYBgRavzE2pvFJMkO-ks5sdaJdgaJpZM4PHFSN .

rossant commented 7 years ago

should be fixed on alyx-dev (water_history pull request https://github.com/cortex-lab/alyx/pull/377)

peterzh commented 7 years ago

I fixed the error by removing all water administration entries with 0.0mL volume. So this error seems to show up when you have 0 as the water amount.

rossant commented 7 years ago

the error is still there on alyx-dev? it should have been fixed.

peterzh commented 7 years ago

I haven't tried on alyx-dev, I was talking about regular alyx.

k1o0 commented 6 years ago

This is now resolved.