Playout endpoint results in Error 500
The endpoint /api/v1/playout
results in Server Error 500
.
The logs also show:
aura-web-nginx-1 | 172.24.0.1 - - [24/Feb/2023:11:36:48 +0100] "GET /steering/api/v1/playout HTTP/1.1" 500 156 "-" "python-requests/2.28.2" "-"
steering | ERROR:django.request:Internal Server Error: /api/v1/playout
steering | Traceback (most recent call last):
steering | File "/app/.cache/virtualenvs/steering-9TtSrW0h-py3.10/lib/python3.10/site-packages/django/core/handlers/exception.py", line 47, in inner
steering | response = get_response(request)
steering | File "/app/.cache/virtualenvs/steering-9TtSrW0h-py3.10/lib/python3.10/site-packages/django/core/handlers/base.py", line 181, in _get_response
steering | response = wrapped_callback(request, *callback_args, **callback_kwargs)
steering | File "/app/program/views.py", line 218, in json_playout
steering | schedule.append(timeslot_entry(timeslot=last_timeslot))
steering | File "/app/program/views.py", line 84, in timeslot_entry
steering | show = timeslot.show
steering | AttributeError: 'NoneType' object has no attribute 'show'