learningequality / learningequality/studio

Historically image files have not been associated with their assessment items

Open
#5,074 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
191
Forks
307
Avg merge
5d 6h
Merged PRs (30d)
10

Description

This issue is not open for contribution. Visit Contributing guidelines to learn about the contributing process and how to find suitable issues.

Observed behavior

https://github.com/learningequality/studio/pull/5072 resolves a long standing bug whereby images were being incorrectly detected in assessment item json/markdown fields. Going forwards, this should now be handled properly, but for any assessment item images uploaded prior to this fix, the files are not properly tracked.

This may mean if the assessment items are subsequently updated, that either the user suddenly is responsible for a large number of image files, or possibly that updates will fail if the file does not have an associated file object in the database.

Expected behavior

Before running this migration, we need to fix this issue: https://github.com/learningequality/studio/issues/3306 and also ensure that users are not responsible (storage wise) for images in imported assessments that they have not edited.

We should:

  • Run a migration to properly associate file objects with all assessment items.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing issue #3306 and pull request #5072, then locate the assessment-item and file-object migration entry points. The work is done when existing assessment item images are associated correctly and imported images do not create storage responsibility for users who have not edited them.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
database
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.