Commit 86bb7b3
committed
refactor: remove UUID field from ComponentVersionContent
It's wasteful to have a UUID on this join table, as we already have
a unique way to address everything in it by the unique combination
of the ComponentVersion (PublishableEntityVersion) and the
ComponentVersionContent.key (file path).
Dropping this column may cause transient errors for some sites if
someone is creating components after the column was dropped, but
before the new app code is live. UUIDs are generated on the Python
side, so Django will try to generate a UUID to put into a column
that has already been dropped on the database side.
That being said, this window of time should be small, and this
feature is not in widespread use yet. I don't think a more complex
migration is warranted.1 parent 2644032 commit 86bb7b3
2 files changed
Lines changed: 18 additions & 3 deletions
File tree
- openedx_learning/apps/authoring/components
- migrations
Lines changed: 17 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
24 | | - | |
| 24 | + | |
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| |||
240 | 240 | | |
241 | 241 | | |
242 | 242 | | |
243 | | - | |
244 | | - | |
245 | 243 | | |
246 | 244 | | |
247 | 245 | | |
| |||
0 commit comments