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

Replace multiselectfield #1072

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from
Open

Replace multiselectfield #1072

wants to merge 3 commits into from

Conversation

okaycj
Copy link
Contributor

@okaycj okaycj commented Jan 25, 2023

To get ready to update Django (#1051), the django-multiselectfield package needs to be removed. By all accounts, the library hasn't been updated since the beginning of 2021.

In order to replace the multiselect field with a bit field, the string values had to be compared to the list of choices and get the index. The index is masked and then or'd with all selections for that field.

The US Ethnicity field is the only field that needed to be migrated away from multiselect.

Screenshot 2023-01-25 at 2 44 21 PM

@okaycj okaycj force-pushed the replace-multiselectfield branch from 6e59532 to 332a326 Compare January 25, 2023 19:49
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@mekline
Copy link
Contributor

mekline commented Jan 26, 2023

Can you confirm that other checkbox choices, like the big list of languages people can choose when creating/modifying a Child, are not affected by this? Just wasn't clear from what you wrote above.

Copy link
Contributor

@mekline mekline left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you confirm that other checkbox choices, like the big list of languages people can choose when creating/modifying a Child, are not affected by this? Just wasn't clear from what you wrote above.

@okaycj okaycj force-pushed the replace-multiselectfield branch from 332a326 to 9552222 Compare April 24, 2023 17:01
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@becky-gilbert
Copy link
Contributor

Can you confirm that other checkbox choices, like the big list of languages people can choose when creating/modifying a Child, are not affected by this? Just wasn't clear from what you wrote above.

@mekline I can confirm that the US ethnicity question is the only one that uses multiselectfield. The other multi-select questions, like child languages and existing conditions, are already using the BitField type that CJ is switching to here.

@okaycj happy to approve this pending the fix to circleci build-and-test 🙂

Also I noticed that the question text that is currently live on staging/develop looks different to that in your screenshot above:

Screenshot 2023-04-25 at 10 23 59 AM

Note the slight difference in question text:

What racial group(s) does your family identify with/belong to? Please select any that apply to someone in your children's immediate family.

And the help text below the question, which is missing in the screenshot above:

Please select the appropriate responses for everyone in your children's immediate family.

But it doesn't look like you've changed/removed the question or help text in this PR, so maybe the screenshot above (from Jan 25th) is just out of date?

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.

3 participants