Closed ZelphirKaltstahl closed 6 months ago
While searching in old issues in the grader-service for "release", we found an old issue: https://github.com/TU-Wien-dataLAB/Grader-Service/issues/93. In this issue there is a fix for apparently the same error or at least very similar error: https://github.com/TU-Wien-dataLAB/Grader-Service/commit/944d312fa6bf9527f6b9aeca122e700cb4c4db09#diff-2d8ae30c5ae615a4861bdadd5c45be1e79750c5a31f3effe721f57e0e7f7e4b6
At first we thought that we had a different issue, because the fix was merged already 6 months ago. However, we still saw the old way of accessing the self.current_user
, instead of using self.current_user.name
, our code seemed to use self.current_user['name']
still. This made us question, whether we had the commit of that fix in our version of the grader labextension. So we checked the code that gets installed with:
RUN pip install --no-cache-dir \
nbclassic==0.3.7 \
grader-convert==0.2.3 \
grader-service==0.3.0 \
grader-labextension==0.3.0
in our Dockerfile
. Trying to install the extension in editable (pip install -e
) mode was too cumbersome, because of the dependency to npm
or yarn
. So instead we checked the code installed in the Python environment's .../lib/python3.11/site-packages/grader_labextension/handlers/base_handler.py
.
Indeed, it was still using the old way of accessing the name
attribute.
So we edited that code to also use self.current_user.name
instead of self.current_user['name']
.
Then we restarted the docker container, so that the Python process reads these files anew, when the labextension becomes active.
And then things seem to work =)
So it seems, that while splitting out the labextension recently this fix of https://github.com/TU-Wien-dataLAB/Grader-Service/commit/944d312fa6bf9527f6b9aeca122e700cb4c4db09#diff-2d8ae30c5ae615a4861bdadd5c45be1e79750c5a31f3effe721f57e0e7f7e4b6 was not taken with the labextension to the new labextension repository.
Solved, merge request merged.
Description
Using the released grader labextension
0.3.0
, an instructor cannot release an assignment. There might be more factors contributing to this bug, as we have a different setup, that uses DockerSpawner instead of the local system process spawner in our JupyterHub setup, but bear with me:The error happens when setting the commit message when releasing and clicking "COMMIT AND RELEASE":
The logs of the corresponding user docker container show the following error:
A clear and concise description of what the bug is.
How to reproduce
I might be able to share the complete setup with dockerfiles and so on later, but that is not a certainty. But I will try to describe how to reproduce this.
lect1
:Expected behavior
The assignment should be successfully released.
Screenshots
(see above)
Desktop
115.7.0esr (64-bit)
Apple M1 Pro, MacOS 14.2.1
Version 109.0.5414.87 (Official Build) (arm64)
Additional context
We have separated out the spawned JupyterLab instances from the JupyterHub container into separate user containers using the
DockerSpawner
. This means, that the setup is significantly different. However, we already found the apparent fix for the problem. Will post in this issue.