Skip to content

Release 0.59.12#3125

Open
odlbot wants to merge 10 commits intoreleasefrom
release-candidate
Open

Release 0.59.12#3125
odlbot wants to merge 10 commits intoreleasefrom
release-candidate

Conversation

@odlbot
Copy link
Copy Markdown
Contributor

@odlbot odlbot commented Mar 27, 2026

Ahtesham Quraish

Matt Bertrand

Zaman Afzal

Chris Chudzicki

zamanafzal and others added 10 commits March 27, 2026 00:54
* fix: Handle image stretch on product page
…and course enrollment button (#3109)

* fix: Handle missing financial_assistance_form_url on product summary and course enrollment button
…3116)

Switch from Boolean(certificate_type) to the new certificate_available
boolean for both courses and programs. Bump mitxonline-api-axios to
2026.3.26 which adds certificate_available to programs.

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
* feat: implement bundle upsell design

* fix test

---------

Co-authored-by: Ahtesham Quraish <ahtesham.quraish@192.168.10.33>
* fix: implement the new UAI card

* small fix

---------

Co-authored-by: Ahtesham Quraish <ahtesham.quraish@192.168.10.33>
Co-authored-by: Chris Chudzicki <christopher.chudzicki@gmail.com>
Co-authored-by: Ahtesham Quraish <ahtesham.quraish@A006-01455.local>
@github-actions
Copy link
Copy Markdown

OpenAPI Changes

Show/hide 26 changes: 0 error, 26 warning, 0 info
26 changes: 0 error, 26 warning, 0 info
warning	[response-optional-property-removed] at head/openapi/specs/v0.yaml	
	in API GET /api/v0/vector_learning_resources_search/
		removed the optional property 'results/items/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/featured/
		removed the optional property 'results/items/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/featured/{id}/
		removed the optional property '/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learning_resources/
		removed the optional property 'results/items/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learning_resources/{id}/
		removed the optional property '/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API PATCH /api/v1/learning_resources/{id}/learning_paths/
		removed the optional property '/items/resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learning_resources/{id}/similar/
		removed the optional property '/items/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API PATCH /api/v1/learning_resources/{id}/userlists/
		removed the optional property '/items/resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learning_resources/{id}/vector_similar/
		removed the optional property '/items/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learning_resources/{learning_resource_id}/items/
		removed the optional property 'results/items/resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learning_resources/{learning_resource_id}/items/{id}/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learning_resources_search/
		removed the optional property 'results/items/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learningpaths/{learning_resource_id}/items/
		removed the optional property 'results/items/resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API POST /api/v1/learningpaths/{learning_resource_id}/items/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '201' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/learningpaths/{learning_resource_id}/items/{id}/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API PATCH /api/v1/learningpaths/{learning_resource_id}/items/{id}/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/podcasts/{learning_resource_id}/items/
		removed the optional property 'results/items/resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/podcasts/{learning_resource_id}/items/{id}/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/userlists/{userlist_id}/items/
		removed the optional property 'results/items/resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API POST /api/v1/userlists/{userlist_id}/items/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '201' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/userlists/{userlist_id}/items/{id}/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API PATCH /api/v1/userlists/{userlist_id}/items/{id}/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/video_playlists/{learning_resource_id}/items/
		removed the optional property 'results/items/resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/video_playlists/{learning_resource_id}/items/{id}/
		removed the optional property 'resource/allOf[#/components/schemas/LearningResource]/oneOf[#/components/schemas/VideoResource]/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/videos/
		removed the optional property 'results/items/video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status

warning	[response-optional-property-removed] at head/openapi/specs/v1.yaml	
	in API GET /api/v1/videos/{id}/
		removed the optional property 'video/allOf[#/components/schemas/Video]/transcript' from the response with the '200' status


Unexpected changes? Ensure your branch is up-to-date with main (consider rebasing).

Comment on lines +142 to +146
if (
learning_resource_obj.resource_type == LearningResourceType.video.name
and hasattr(learning_resource_obj, "video")
):
serialized_data["video"]["transcript"] = learning_resource_obj.video.transcript
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: The code attempts to access serialized_data["video"]["transcript"] without first checking if serialized_data["video"] is None. This will cause a TypeError during OpenSearch indexing for videos without a related video object.
Severity: HIGH

Suggested Fix

Before attempting to assign the transcript, add a check to ensure the video key exists in serialized_data and its value is not None. For example, use if serialized_data.get("video"): before the assignment serialized_data["video"]["transcript"] = ....

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: learning_resources_search/serializers.py#L142-L146

Potential issue: The code attempts to assign a transcript to
`serialized_data["video"]["transcript"]`. However, the `video` field in
`serialized_data` can be `None` if a `LearningResource` of type video does not have an
associated `Video` object, as `VideoResourceSerializer` has `allow_null=True`. The
current check, `hasattr(learning_resource_obj, "video")`, only verifies the model field
exists, not that the serialized value is non-null. When `serialized_data["video"]` is
`None`, the assignment will raise a `TypeError`, causing OpenSearch indexing tasks to
fail for these specific resources.

Did we get this right? 👍 / 👎 to inform future reviews.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants