For Module 2 Graded Lab of the Agentic AI course, I keep getting the below error messages when I submit the assignment. This is despite getting 'All Tests Passed’ when I test the code for each exercise.
Things I have tried include:
- Kernel → Restart & Clear Output
- Restore to Original Version and saving the file under a new name
- Re-run the codes from beginning to end
Is anyone able to help please?
Many thanks in advance! ![]()
Error messages:
Total Score
Try Again・0/30
Exercise 1
0/10
Failed test case: generate_draft raised LLMError: An error occurred: Error code: 400 - {‘error’: {‘message’: “Invalid value for ‘content’: expected a string, got null.”, ‘type’: ‘invalid_request_error’, ‘param’: ‘messages.[0].content’, ‘code’: None}}.
Expected:
no exception,
but got:
An error occurred: Error code: 400 - {‘error’: {‘message’: “Invalid value for ‘content’: expected a string, got null.”, ‘type’: ‘invalid_request_error’, ‘param’: ‘messages.[0].content’, ‘code’: None}}.
Exercise 2
0/10
Failed test case: reflect_on_draft raised LLMError: An error occurred: Error code: 400 - {‘error’: {‘message’: “Invalid value for ‘content’: expected a string, got null.”, ‘type’: ‘invalid_request_error’, ‘param’: ‘messages.[0].content’, ‘code’: None}}.
Expected:
no exception,
but got:
An error occurred: Error code: 400 - {‘error’: {‘message’: “Invalid value for ‘content’: expected a string, got null.”, ‘type’: ‘invalid_request_error’, ‘param’: ‘messages.[0].content’, ‘code’: None}}.
Exercise 3
0/10
Failed test case: revise_draft raised AttributeError: ‘NoneType’ object has no attribute ‘choices’.
Expected:
no exception,
but got:
‘NoneType’ object has no attribute ‘choices’.