Skip to content

Commit

Permalink
CLN lint
Browse files Browse the repository at this point in the history
  • Loading branch information
wabscale committed Apr 17, 2024
1 parent fddb516 commit c470b70
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 7 deletions.
2 changes: 0 additions & 2 deletions api/anubis/views/admin/courses.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,8 @@
from sqlalchemy.exc import DataError, IntegrityError

from anubis.github.team import add_github_team_member, remote_github_team_member
from anubis.k8s.pvc.get import get_user_pvc
from anubis.lms.courses import assert_course_superuser, course_context, valid_join_code
from anubis.models import Course, InCourse, ProfessorForCourse, TAForCourse, User, db
from anubis.models.id import default_id_factory
from anubis.rpc.enqueue import enqueue_bulk_create_students
from anubis.utils.auth.http import require_admin, require_superuser
from anubis.utils.auth.user import current_user
Expand Down
9 changes: 4 additions & 5 deletions api/anubis/views/super/students.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@

from anubis.lms.students import get_students
from anubis.models import User, db
from anubis.rpc.enqueue import enqueue_reap_pvc_user
from anubis.utils.auth.http import require_superuser
from anubis.utils.data import req_assert
from anubis.utils.http import success_response
from anubis.utils.http.decorators import json_response, json_endpoint
from anubis.rpc.enqueue import enqueue_reap_pvc_user

students_ = Blueprint("super-students", __name__, url_prefix="/super/students")

Expand Down Expand Up @@ -149,7 +149,7 @@ def super_students_delete_pvc(id: str):
enqueue_reap_pvc_user(id)

return success_response({
"status": f"Volume deletion scheduled for user: {other.netid}.",
"status": f"Volume deletion scheduled for user: {other.netid}.",
"variant": "warning"
})

Expand All @@ -168,7 +168,7 @@ def super_students_add(netid: str, name: str):
if user is not None:
return success_response({
"status": f"Student already exists {netid}",
"user": user.data,
"user": user.data,
})

user = User(netid=netid.strip(), name=name.strip())
Expand All @@ -177,6 +177,5 @@ def super_students_add(netid: str, name: str):

return success_response({
"status": f"Added student {netid}",
"user": user.data,
"user": user.data,
})

0 comments on commit c470b70

Please sign in to comment.