-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Data model for explicit storage of restricted runs and their courses #963
Conversation
...apps/catalog/migrations/0040_rename_json_metadata_contentmetadata__json_metadata_and_more.py
Outdated
Show resolved
Hide resolved
63f996d
to
d7a8efa
Compare
migrations.AlterField( | ||
model_name='catalogquery', | ||
name='content_filter', | ||
field=jsonfield.fields.JSONField(default=dict, dump_kwargs={'cls': jsonfield.encoder.JSONEncoder, 'ensure_ascii': False, 'indent': 4, 'separators': (',', ':')}, help_text="Query parameters which will be used to filter the discovery service's search/all endpoint results, specified as a JSON object.", load_kwargs={'object_pairs_hook': collections.OrderedDict}), | ||
), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why on earth is this being altered?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll rebase on alex's PR to fix this. #967
46d70a8
to
c68ee7c
Compare
3d0d816
to
045086f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is looking good! It's reassuring that the changes in test files are all either net-new tests, or swapping json_metadata
for _json_metadata
. I'll try to run through your spike test on my machine today.
e0ff291
to
a95d658
Compare
migrations.AddField( | ||
model_name='restrictedcoursemetadata', | ||
name='unrestricted_parent', | ||
field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='restricted_courses', to='catalog.contentmetadata'), | ||
), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why would django decide to introduce AddField to the exact same migration where the model is being introduced via CreateModel?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think because it's a FK?
a95d658
to
b04b56d
Compare
b04b56d
to
98c3353
Compare
ENT-9569