ucbds-infra / otter-grader

A Python and R autograding solution
https://otter-grader.readthedocs.io
BSD 3-Clause "New" or "Revised" License
126 stars 66 forks source link

Sunsetting Mambaforge #846

Closed nibheis closed 1 month ago

nibheis commented 1 month ago

Describe the bug Since October 1st 2024, mambaforge no longer installs ; otter grade fails to generate docker images.

To Reproduce Steps to reproduce the behavior:

  1. Clean all docker cache/images/etc.
  2. Run otter gade on docker

Expected behavior otter should use miniforge (see here) and generate docker images correctly.

Versions Tested with otter 5.5.0 and 5.6.0

Additional context I managed to get the docker image built by manually patching the zip file and changing setup.sh:

...
if [ $(uname -p) = "arm" ] || [ $(uname -p) = "aarch64" ] ; \
    then wget -nv https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge-pypy3-Linux-aarch64.sh \
        -O /autograder/source/mamba_install.sh ; \
    else wget -nv https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge-pypy3-Linux-x86_64.sh \
        -O /autograder/source/mamba_install.sh ; \
fi
...
echo "export PATH=/root/miniforge-pypy3/bin:\$PATH" >> /root/.bashrc
export PATH=/root/miniforge-pypy3/bin:$PATH
...

and run_autograder:

#!/usr/bin/env bash
export PATH="/root/miniforge-pypy3/bin:$PATH"
source /root/miniforge-pypy3/etc/profile.d/conda.sh
source /root/miniforge-pypy3/etc/profile.d/mamba.sh
mamba activate otter-env
codingPie commented 1 month ago

Thanks for the issue posting. I am struggling with the same problem. Will we get notified when the fix is released? At the same time, I will try to manually change the setup.sh. Hopefully this works. The assignment is due this Friday ...

chrispyles commented 1 month ago

I am working on #847 to switch from mambaforge to miniforge. Once that's done I'll release v5.7.0.

codingPie commented 1 month ago

Thanks!

chrispyles commented 1 month ago

v5.7.0 is now up.

codingPie commented 1 month ago

Hi @chrispyles how do I upgrade my version of otter grader (5.5) to v5.7.0? I used pip install when I first get the Otter grader. I downloaded your tar.gz file but don't know how to update my own version. Do I need to ask students to update their Otter grader installation as well?

codingPie commented 1 month ago

I found the command online to be:

pip install --upgrade otter-grader==5.7.0

and now my Otter Grader version is up to date. I guess students don't need to upgrade the grader since this update is only for building the container but would be great if someone can confirm this. Thanks again!

chrispyles commented 1 month ago

@codingPie yes, that’s the correct command. Students don’t need to upgrade since these changes don’t affect student usage.

ylizama commented 1 month ago

Hi!

I upgraded otter-grader satisfactorily. I was able to generate my docker image with no issues.

However, when I test the autograder submitting an assignment, I receive this error:

The exception below was thrown when attempting to read the results from executing the notebook. (This message is not visible to students.) Traceback (most recent call last): File "/root/miniforge3/envs/otter-env/lib/python3.9/site-packages/otter/execute/init.py", line 110, in grade_notebook results = pickle.load(f) EOFError: Ran out of input

chrispyles commented 1 month ago

@ylizama Please follow the steps here to run in debug mode and provide the error message.

ylizama commented 1 month ago

@chrispyles never mind. It was an encoding error on my end. Thanks!