storage location not respected on course import
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 11
- Forks
- 38
- PR merge metrics
- No merged PRs in 30d
Description
When a course with video transcripts is imported, the path location is not respected; it goes in the root of the storage. Everything else (eg. reading transcripts) appears to correctly respect the location.
For example, if I have the following config (tutor default + tutor-contrib-s3):
MEDIA_ROOT = "/openedx/media/"
VIDEO_TRANSCRIPTS_SETTINGS["STORAGE_KWARGS"]["location"] = MEDIA_ROOT
STORAGES['default']['BACKEND'] = "storages.backends.s3boto3.S3Boto3Storage"
VIDEO_TRANSCRIPTS_SETTINGS["STORAGE_KWARGS"]["location"] = VIDEO_TRANSCRIPTS_SETTINGS["STORAGE_KWARGS"]["location"].lstrip("/")
And I import a course with transcripts, the transcripts will be saved to video-transcripts/ in s3, but it will try reading the transcripts from openedx/media/video-transcripts.
I believe I've been able to reproduce similar behaviour with the new STORAGES based setting, although I think maybe the transcript file didn't get uploaded at all. Perhaps more testing is required there:
STORAGES["video_transcripts"] = {
"BACKEND": "storages.backends.s3boto3.S3Boto3Storage",
"OPTIONS": {
"bucket_name": "{{ S3_STORAGE_BUCKET }}",
"location": "",
},
}
This is on Verawood.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the course import path that handles video transcripts and trace how VIDEO_TRANSCRIPTS_SETTINGS and the video_transcripts STORAGES configuration determine upload and read locations. Reproduce the issue with the provided S3 configurations; done means imported transcripts are uploaded under the configured location and can be read from that same location.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- aws, python
- Domain
- backend, cloud
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Mostly clear
- Newbie friendliness
- 65/100