You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When I create a file as teacher that doesn't exist in the student's submission and then edit the same file as student, then the file becomes unreadable as the teacher.
cgfs traceback:
Traceback (most recent call last):
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/fuse.py", line 495, in _wrapper
return func(*args, **kwargs) or 0
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/fuse.py", line 511, in getattr
return self.fgetattr(path, buf, None)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/fuse.py", line 759, in fgetattr
attrs = self.operations('getattr', self._decode_optional_path(path), fh)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/fuse.py", line 972, in __call__
ret = getattr(self, op)(path, *args)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/codegra_fs/cgfs.py", line 1356, in getattr
return self._getattr(path, fh)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/codegra_fs/cgfs.py", line 1382, in _getattr
attrs = file.getattr(submission, query_path)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/codegra_fs/cgfs.py", line 896, in getattr
super(File, self).getattr(submission, path)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/codegra_fs/cgfs.py", line 68, in getattr
stat = cgapi.get_file_meta(submission.id, path)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/codegra_fs/cgapi.py", line 193, in get_file_meta
self._handle_response_error(r)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/codegra_fs/cgapi.py", line 164, in _handle_response_error
raise CGAPIException(request)
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/codegra_fs/cgapi.py", line 128, in __init__
data = response.json()
File "/home/olmo/code/CodeGra.fs/env/lib/python3.6/site-packages/requests/models.py", line 892, in json
return complexjson.loads(self.text, **kwargs)
File "/usr/lib64/python3.6/json/__init__.py", line 354, in loads
return _default_decoder.decode(s)
File "/usr/lib64/python3.6/json/decoder.py", line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/lib64/python3.6/json/decoder.py", line 357, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
server traceback
127.0.0.1 - - [19/Feb/2018 17:54:17] "GET /api/v1/submissions/2/files/?path=Top%20stub%20dir/main.c&owner=auto HTTP/1.1" 500 -
Traceback (most recent call last):
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/app.py", line 1997, in __call__
return self.wsgi_app(environ, start_response)
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/app.py", line 1985, in wsgi_app
response = self.handle_exception(e)
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/app.py", line 1540, in handle_exception
reraise(exc_type, exc_value, tb)
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/_compat.py", line 33, in reraise
raise value
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/app.py", line 1982, in wsgi_app
response = self.full_dispatch_request()
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/app.py", line 1614, in full_dispatch_request
rv = self.handle_user_exception(e)
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/app.py", line 1517, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/_compat.py", line 33, in reraise
raise value
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/app.py", line 1612, in full_dispatch_request
rv = self.dispatch_request()
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/flask/app.py", line 1598, in dispatch_request
return self.view_functions[rule.endpoint](**req.view_args)
File "/home/olmo/code/CodeGra.de/psef/auth.py", line 83, in wrapper
return fn(*args, **kwargs)
File "/home/olmo/code/CodeGra.de/psef/v1/submissions.py", line 659, in get_dir_contents
found_file = work.search_file(path, exclude_owner)
File "/home/olmo/code/CodeGra.de/psef/models.py", line 1472, in search_file
File.is_directory == is_dir,
File "/home/olmo/code/CodeGra.de/psef/helpers.py", line 249, in filter_single_or_404
return t.cast(Y, _filter_or_404(model, False, criteria))
File "/home/olmo/code/CodeGra.de/psef/helpers.py", line 206, in _filter_or_404
obj = query.all() if get_all else query.one_or_none()
File "/home/olmo/code/CodeGra.de/env/lib/python3.6/site-packages/sqlalchemy/orm/query.py", line 2816, in one_or_none
"Multiple rows were found for one_or_none()")
sqlalchemy.orm.exc.MultipleResultsFound: Multiple rows were found for one_or_none()
The text was updated successfully, but these errors were encountered:
When I create a file as teacher that doesn't exist in the student's submission and then edit the same file as student, then the file becomes unreadable as the teacher.
cgfs traceback:
server traceback
The text was updated successfully, but these errors were encountered: