Library V2 video transcripts: path stored as static/… and read as static/static/… (download 404, LMS 404, orphan asset on delete)
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 3/5
- Tiempo estimado
- Medio día
- Aptitud para principiantes
- 42/100
Línea de trabajo
Start with openedx/core/djangoapps/video_config/services.py around line 231 (upload stores the 'static/' prefixed name) and line 282 (delete), then openedx/core/djangoapps/video_config/transcripts_utils.py around line 1004 (get_transcript_from_openedx_content). Reproduce via the studio_transcript handler on a V2 library video, then decide whether to store the bare filename or strip the prefix in readers. Done when upload, download and delete round-trip with no 404 and no orphaned asset, covered by a library test.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Summary
For a Video in a Content Library V2, an uploaded transcript can't be downloaded, doesn't reach the LMS on a reused copy, and leaves an orphan file on delete. The transcript file path is stored with a static/ prefix, and the readers add static/ again.
Steps to reproduce
Found while smoke-testing openedx/openedx-platform#38750 on a local Tutor nightly (master base 6f85d63c7f, xblocks-core 2.0.0):
- Create a Video in a V2 library and upload an
.srtthrough thestudio_transcripthandler (POST .../handler/studio_transcript/translationwithlanguage_code=en,new_language_code=en,file). → 201. - The block's
transcriptsfield is now{"en": "static/transcript-en.srt"}, and the component has assetstatic/transcript-en.srt. GET .../studio_transcript/translation?language_code=en→ 404.- Publish and reuse the video in a course: the LMS player metadata lists
en, but.../handler/transcript/translation/en→ 404. - Delete via
DELETE .../studio_transcript/translation{"lang": "en", "edx_video_id": ""}→ 200. The field is cleared, but the assetstatic/transcript-en.srtremains.
Cause
- Upload:
openedx/core/djangoapps/video_config/services.py:231setsfilename = f'static/transcript-{new_language_code}.srt'and stores it invideo_block.transcripts[lang]. - Read:
openedx/core/djangoapps/video_config/transcripts_utils.py:1004(get_transcript_from_openedx_content) buildspathlib.Path(f"static/{transcripts[language]}"), givingstatic/static/transcript-en.srt. - Delete:
services.py:282deletesf"static/{transcript_name}", which also doubles the prefix, so the asset is never removed.
The prefix was already stored this way in the built-in video_handlers.py before the logic moved to VideoConfigService (3c9e1a90de), so this predates the XBlock extraction. The get_transcript_from_openedx_content docstring expects the field to hold the bare filename ({"en": "3_yD_cEKoCk-en.srt"}).
Suggested fix
Store the bare filename in transcripts (keep static/ only for the asset path), or strip a leading static/ in the readers and in delete for existing data. Add a library upload → download → delete round-trip test.
| Generated using Claude Code
- Lenguaje dominante
- Python
- Estrellas
- 8.2k
- Forks
- 4.4k
- Merge medio
- 2 d 10 h
- PR fusionados (30 d)
- 40
Preparar el entorno
- Sin Dockerfile ni archivo de Docker Compose
- Tiene una plantilla de pull request
- Leer la guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de openedx/openedx-platform
-
Discussion API: missing thread returns 500 (ForumV2RequestError not mapped to ThreadNotFoundError)Quizá libre de nuevo @mbhavu2007-lang la tomó hace 16 días y no hay ningún pull request abierto. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
openedx/openedx-platform#39225 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
v3 notification preferences: PUT with email_cadence but no notification_channel raises KeyError (500)Quizá libre de nuevo Un pull request para esta issue se cerró sin fusionarse. Abiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
openedx/openedx-platform#39221 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 86/100
openedx/openedx-platform#39169 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
openedx/openedx-platform#39084 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 Menos de una hora Aptitud para principiantes 82/100
openedx/openedx-platform#38792 ·
Los mantenedores suelen responder en 1 día
Todos los issues de openedx/openedx-platform
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
eugr/spark-vllm-docker#469 ·
-
Beam search pads finished sequences with eos_token_id instead of pad_token_id when pad_token_id=0Abiertobug
Dificultad 2/5 1-3 horas Aptitud para principiantes 77/100
huggingface/transformers#50857 ·
Los mantenedores suelen responder en 1 día
-
AMD test-suite combiner deduplicates with a linear list scan, giving quadratic work in suite sizeAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
vllm-project/vllm-omni#10506 ·
Los mantenedores suelen responder en 1 día
-
enhancement p2 tests
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
amd/gaia#8392 · 2 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
can4hou6joeng4/boss-agent-cli#1487 ·
Los mantenedores suelen responder en 1 día