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

STCOR-906 consume react-query QueryClient in <Logout> #1567

Merged
merged 3 commits into from
Nov 27, 2024
Merged

Conversation

zburke
Copy link
Member

@zburke zburke commented Nov 26, 2024

Correctly pass all three required arguments from <Logout> to loginServices::logout(): gateway URL, redux store, react-query QueryClient. The third was missing, resulting in an NPE during logout() that caused flow to skip to the finally clause, skipping the code that cleared localforage. Sometimes localforage appears to get cleared anyway, but sometimes not, in which case the session may fail to terminate even when the fixed-length session timer reaches 00:00.

This is one of those "How did this ever work?!? And how did we not notice?!?" situations.

Refs STCOR-906

Correctly pass all three required arguments from `<Logout>` to
`loginServices::logout()`: gateway URL, redux store, react-query
QueryClient. The third was missing, resulting in an NPE during
`logout()` that caused flow to skip to the `finally` clause, skipping
the code that cleared localforage. Sometimes localforage appears to get
cleared anyway, but sometimes not, in which case the session may fail to
terminate even when the fixed-length session timer reaches 00:00.

This is one of those "How did this ever work?!? And how did we not
notice?!?" situations.

Refs STCOR-906
Copy link

github-actions bot commented Nov 26, 2024

Bigtest Unit Test Results

192 tests  ±0   187 ✅ ±0   6s ⏱️ ±0s
  1 suites ±0     5 💤 ±0 
  1 files   ±0     0 ❌ ±0 

Results for commit a969f5f. ± Comparison against base commit 1c73afd.

This pull request removes 5 and adds 3 tests. Note that renamed tests count towards both.
      equal to check email label in english translation
      equal to check email precautions label in english translation
      equal to sent email precautions label in english translation
Chrome_131_0_0_0_(Linux_x86_64).Forgot username/password status test check email status page tests ‑ Forgot username/password status test check email status page tests should have the header with an appropriate text content
Chrome_131_0_0_0_(Linux_x86_64).Forgot username/password status test check email status page tests ‑ Forgot username/password status test check email status page tests should have the paragraph with an appropriate text content
Chrome_131_0_0_0_(Linux_x86_64).Forgot username/password status test check email status page tests ‑ Forgot username/password status test check email status page tests should have the header with an appropriate text content
      equal to check email label in english translation
Chrome_131_0_0_0_(Linux_x86_64).Forgot username/password status test check email status page tests ‑ Forgot username/password status test check email status page tests should have the paragraph with an appropriate text content
      equal to check email precautions label in english translation
Chrome_131_0_0_0_(Linux_x86_64).Forgot username/password status test check email status page tests ‑ Forgot username/password status test check email status page tests should have the paragraph with an appropriate text content
      equal to sent email precautions label in english translation

♻️ This comment has been updated with latest results.

Copy link

github-actions bot commented Nov 26, 2024

Jest Unit Test Results

  1 files  ±0   55 suites  ±0   1m 33s ⏱️ +2s
349 tests +1  349 ✅ +1  0 💤 ±0  0 ❌ ±0 
352 runs  +1  352 ✅ +1  0 💤 ±0  0 ❌ ±0 

Results for commit a969f5f. ± Comparison against base commit 1c73afd.

♻️ This comment has been updated with latest results.

Copy link
Member

@ryandberger ryandberger left a comment

Choose a reason for hiding this comment

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

Lint, but otherwise good to go!

@zburke zburke merged commit 9534433 into master Nov 27, 2024
16 checks passed
@zburke zburke deleted the STCOR-906 branch November 27, 2024 16:44
zburke added a commit that referenced this pull request Dec 2, 2024
Correctly pass all three required arguments from `<Logout>` to
`loginServices::logout()`: gateway URL, redux store, react-query
QueryClient. The third was missing, resulting in an NPE during
`logout()` that caused flow to skip to the `finally` clause, skipping
the code that cleared localforage. Sometimes localforage appears to get
cleared anyway, but sometimes not, in which case the session may fail to
terminate even when the fixed-length session timer reaches 00:00.

This is one of those "How did this ever work?!? And how did we not
notice?!?" situations.

Refs [STCOR-906](https://folio-org.atlassian.net/browse/STCOR-906)

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