Skip to content

LG-4637: Show accurate time remaining for IAL2 throttle screens#5301

Merged
aduth merged 3 commits intomainfrom
aduth-lg-4637-throttle-time
Sep 1, 2021
Merged

LG-4637: Show accurate time remaining for IAL2 throttle screens#5301
aduth merged 3 commits intomainfrom
aduth-lg-4637-throttle-time

Conversation

@aduth
Copy link
Copy Markdown
Contributor

@aduth aduth commented Aug 17, 2021

Why: As a user, I expect that if I encounter an error screen informing me that I am unable to proceed due to too many attempts, the text on the page will let me know when I can try again, so that I know when to return to try again, and so that I'm not waiting longer than necessary if I can try again sooner than the text would otherwise imply.

Screenshot:

Screen Before After
Session Error Screen Shot 2021-08-17 at 3 17 37 PM Screen Shot 2021-08-17 at 3 17 25 PM
SSN Error Screen Shot 2021-08-17 at 3 17 37 PM Screen Shot 2021-08-31 at 8 41 40 AM
Phone Error Screen Shot 2021-08-31 at 8 59 12 AM Screen Shot 2021-08-31 at 9 00 07 AM
Send Link localhost_3000_verify_doc_auth_send_link localhost_3000_verify_doc_auth_send_link (1)
GPO Verify localhost_3000_account_verify localhost_3000_account_verify (2)
Reverify Key Screen Shot 2021-09-01 at 3 24 30 PM Screen Shot 2021-09-01 at 3 24 19 PM

@aduth aduth force-pushed the aduth-lg-4637-throttle-time branch from 296cf9e to bd57718 Compare August 20, 2021 14:34
@aduth aduth marked this pull request as ready for review August 20, 2021 14:35
@aduth
Copy link
Copy Markdown
Contributor Author

aduth commented Aug 20, 2021

There's another instance of this message I still need to deal with for phone failure:

timeout: distance_of_time_in_words(
IdentityConfig.store.idv_attempt_window_in_hours.hours,
),

This looks a bit complicated to address, because of how there seems to be a separate throttling mechanism using the IDV session (example). I'm not sure if there was a compelling reason to do it this way, or if we could migrate these to using the standard throttling behaviors.

Copy link
Copy Markdown
Contributor

@zachmargolis zachmargolis left a comment

Choose a reason for hiding this comment

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

LGTM

aduth added a commit that referenced this pull request Aug 30, 2021
… type

**Why**: So that each throttle error screen corresponds to exactly one throttle type, to accommodate accurate time labels proposed in #5301 (LG-4637).
aduth added a commit that referenced this pull request Aug 30, 2021
… type (#5346)

**Why**: So that each throttle error screen corresponds to exactly one throttle type, to accommodate accurate time labels proposed in #5301 (LG-4637).
Comment on lines 17 to 18
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

throttled is for the :idv_acuant throttle type, so this isn't quite correct. Will fix in revisions accounting for separate SSN throttle via #5346. I'll also double-check to see why feature tests didn't flag this.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I'll also double-check to see why feature tests didn't flag this.

There were feature specs for this, but they weren't specifically checking the content as showing an expected time remaining. I've added an extra set of assertions in the rebased 1612180 (see document_capture_step_spec.rb).

**Why**: As a user, I expect that if I encounter an error screen informing me that I am unable to proceed due to too many attempts, the text on the page will let me know when I can try again, so that I know when to return to try again, and so that I'm not waiting longer than necessary if I can try again sooner than the text would otherwise imply.
@aduth aduth force-pushed the aduth-lg-4637-throttle-time branch from 72c28ea to 1612180 Compare August 31, 2021 13:05
@aduth
Copy link
Copy Markdown
Contributor Author

aduth commented Aug 31, 2021

I rebased this to incorporate revisions from #5346 and #5339, and updated original comment to include before / after screenshots for the phone and SSN throttling error screens.

Comment on lines +37 to +38
def ssn_from_doc
user_session&.dig('idv/doc_auth', 'pii_from_doc', 'ssn')
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

A bit more involved to get at the throttle target value for SSN throttling, vs. others just getting by the current user.

aduth added 2 commits August 31, 2021 09:38
**Why**: Fix flakiness with messaging changing by time elapsed
**Why**: Because we've already frozen time for the duration of the tests, it's not necessary. Also, it raises errors.
@aduth aduth merged commit e5b0da6 into main Sep 1, 2021
@aduth aduth deleted the aduth-lg-4637-throttle-time branch September 1, 2021 13:34
zachmargolis pushed a commit that referenced this pull request Sep 1, 2021
* LG-4637: Show accurate time remaining for IAL2 throttle screens

**Why**: As a user, I expect that if I encounter an error screen informing me that I am unable to proceed due to too many attempts, the text on the page will let me know when I can try again, so that I know when to return to try again, and so that I'm not waiting longer than necessary if I can try again sooner than the text would otherwise imply.

* Freeze time for phone throttling specs

**Why**: Fix flakiness with messaging changing by time elapsed

* De-block phone throttling time travel

**Why**: Because we've already frozen time for the duration of the tests, it's not necessary. Also, it raises errors.

(cherry picked from commit e5b0da6)
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.

2 participants