Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PCA Resyncing Logic #668

Merged
merged 15 commits into from
Nov 11, 2024
2 changes: 2 additions & 0 deletions backend/Pipfile
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ python-dateutil = "*"
docutils = "*"
ics = "*"
drf-nested-routers = "*"
asyncio = "*"
aiohttp = "*"

[requires]
python_full_version = "3.11"
190 changes: 108 additions & 82 deletions backend/Pipfile.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 10 additions & 9 deletions backend/alert/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,15 +132,16 @@ def accept_webhook(request):
else:
response = JsonResponse({"message": "webhook recieved"})

u = record_update(
section,
course_term,
prev_status,
course_status,
alert_for_course_called,
request.body,
)
update_course_from_record(u)
with transaction.atomic():
u = record_update(
section,
course_term,
prev_status,
course_status,
alert_for_course_called,
request.body,
)
update_course_from_record(u)
except (ValidationError, ValueError) as e:
logger.error(e, extra={"request": request})
response = JsonResponse(
Expand Down
Loading
Loading