-
Notifications
You must be signed in to change notification settings - Fork 29
Description
grader.cs crashes when loading this exercise model solution:
Is there a mistake in the course configuration or is the course build producing invalid config? The ValueError is suspicious since valid data should not have "2." (NB. period) in an integer field.
File "/mooc-grader/./access/types/forms.py", line 467, in compare_values
return int(val) == int(cmp)
ValueError: invalid literal for int() with base 10: '2.'
From grader.cs log:
[2022-01-07 13:17:12,809: ERROR/log] Internal Server Error: /model/215/python1_python-harjoitukset-1_repl/
Traceback (most recent call last):
File "/usr/local/lib/python3.8/dist-packages/django/core/handlers/exception.py", line 34, in inner
response = get_response(request)
File "/usr/local/lib/python3.8/dist-packages/django/core/handlers/base.py", line 115, in _get_response
response = self.process_exception_by_middleware(e, request)
File "/usr/local/lib/python3.8/dist-packages/django/core/handlers/base.py", line 113, in _get_response
response = wrapped_callback(request, *callback_args, **callback_kwargs)
File "/usr/local/lib/python3.8/dist-packages/aplus_auth/auth/django.py", line 61, in wrapper
return func(request, *args, **kwargs)
File "/mooc-grader/./access/views.py", line 317, in exercise_model
response = import_named(course, exercise['view_type'] + "Model")(request, course, exercise, parameter)
File "/mooc-grader/access/types/stdsync.py", line 160, in createFormModel
points,error_groups,error_fields = form.grade()
File "/mooc-grader/./access/types/forms.py", line 444, in grade
i, ok, p = self.grade_field(i, field)
File "/mooc-grader/./access/types/forms.py", line 579, in grade_field
ok, hints, method = self.grade_text(configuration, value)
File "/mooc-grader/./access/types/forms.py", line 785, in grade_text
correct = self.compare_values(method, value, accept)
File "/mooc-grader/./access/types/forms.py", line 467, in compare_values
return int(val) == int(cmp)
ValueError: invalid literal for int() with base 10: '2.'
Metadata
Metadata
Assignees
Labels
Type
Projects
Status