-
Notifications
You must be signed in to change notification settings - Fork 38
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
issue #1443 added the sis_name retrieval back to user query for UDW cron query #1444
Conversation
… query for UDW cron; will file a UDP request for including Canvas user login_id in UDP, so that we can retrieve the sis_name field in UDP cron, too
I am reviewing it now. |
I ran the cron for UDW queries and I was able to see This change looks good and the query that is revered back exactly that one in the past (i.e the working version) |
With the current code these names are present in the auth_user->username field. However it looks like there's code in the cron that converts the -1 user_id to a numeric value from the user table. I think the better fix for this will be just continuing along and storing the canvas user Id from the launch somewhere and just using that rather than querying from the warehouse. We may need to extend the Django User model.
I guess this is fine for now and probably quickest, but I don't think it's ultimately necessary and can be fixed by:
The biggest negative I can see of this approach is that the canvas_user_id won't be available until the user logs in for the first time. So there will be 24 hours until the cron is able to update for this user to get MiVideo events. I think the only way that could be fixed would be to store either/or the |
This looks good for the UDW, but this also needs to include a fix to pull what we can for UDP. I'm working on that and will test both of these out. |
I tested with both UDW and UDP. You can give it a review if you'd like before merging @zqian. For the UDP it still has the limitation of not being able to return ids for internal or staff accounts. But seems to do fine for students and friend accounts. It does put their ID in there as the name which is better than nothing and maybe all we have for now. |
This is partial revert of cron.hjson change in #1392: restored sis_name, and still leave out the user's name field.
Will file a UDP request for including Canvas user login_id in UDP, so that we can retrieve the sis_name field in UDP cron, too