-
Notifications
You must be signed in to change notification settings - Fork 42
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
app: skip round trip to user endpoint during login (fix #575) #605
Conversation
To clarify, will this break login against unpatched prod instances until 1.2.0? |
once this is merged one can either:
|
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.
- Confirm that login still works
- verify in the diff that there is now no second call to the server prior to the main window being displayed
One thing I'm checking now is if it's fine to call sync_api
after resume_queues
, I think what we want is to continue to call sync_api
before resume_queues
so that new jobs can get added and prioritized before the queue starts again (a higher priority job might need to get bumped to the front of the queue like an auth token reset job. What do you think?
oh yeah, very good point, I will move |
d50a4ea
to
e58a5f8
Compare
e58a5f8
to
7f4b97a
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.
lgtm!
Ah, I marked this as draft to block merge until we bring in the corresponding SDK changes, I'll open a followup for updating to the latest version of the SDK |
Description
Fixes #575 following option 1 presented in the bottom of that ticket: avoiding the round-trip to the /user endpoint by presenting everything we need at login time in the response to the /token endpoint
Test Plan
pip install -e git+https://github.com/freedomofpress/securedrop-sdk.git@token-endpoint-journo-names#egg=securedrop-sdk
Checklist
If these changes modify code paths involving cryptography, the opening of files in VMs or network (via the RPC service) traffic, Qubes testing in the staging environment is required. For fine tuning of the graphical user interface, testing in any environment in Qubes is required. Please check as applicable: