Skip to content
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

Create assigned_homeroom_id key on Educator table, copy to bootstrap, and update importers #2123

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

kevinrobinson
Copy link
Contributor

@kevinrobinson kevinrobinson commented Sep 25, 2018

Who is this PR for?

educators, developers

What problem does this PR fix?

Part of #1880 (comment).

Multiple educators can be assigned to the same homeroom, but Insights doesn't allow this now. This results in the importer process thrashing each day over who is assigned to the homeroom, and effectively alternating who will be authorized to view those students. This isn't user-impacting right now, and it came up from validating the Bedford imports.

The overall idea is to migrate the key to the Educator model, and do this in pieces:

  • add new key, copy values into it
  • run import
  • update read side in model to remove old association, and read from new column (this impacts authorizer, feed, homerooms_controller, class list, paths_for_educator - also need to look at educator.students through homeroom)
  • drop old key
  • migrate column name

Because these are related, once we start we should finish them all to avoid allowing drift during the migration.

What does this PR do?

This PR aims to do the first two items.

Checklists

  • Author included specs for new code

@kevinrobinson
Copy link
Contributor Author

#2162 pointed to this again, looking into Homeroom records failing the validation on name.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant