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

Refactoring QA from unit assign to use in onboarding #960

Merged
merged 2 commits into from
Dec 9, 2022

Conversation

JackUrb
Copy link
Contributor

@JackUrb JackUrb commented Dec 8, 2022

Overview

As noted in #959, passing onboarding led directly to a real unit, even if Screening (or Gold) units are configured. This PR resolves the issue.

Details

  • Assigning a unit from onboarding was a special case execution. This PR abstracts the logic for selecting a QA unit that used to be in register_agent into a separate _assign_unit_or_qa function, so that it can also be called in register_agent_from_onboarding.
  • It also resolves a logging bug in register_agent_from_onboarding in the rare case that a worker passes onboarding, and is only then no longer eligible for a unit due to get_valid_units_for_worker or filter_units_for_worker - these used to be logged as NOT_QUALIFIED but are now appropriately NO_AVAILABLE_UNITS.

Testing

Automated, reproducing the example in #959

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Dec 8, 2022
@JackUrb JackUrb merged commit 0e7dfc7 into main Dec 9, 2022
@JackUrb JackUrb deleted the onboarding-and-other-qa branch December 9, 2022 16:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants