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

Rescue the exception when the logout link is not found #39

Open
jgrevich opened this issue Jul 8, 2021 · 2 comments
Open

Rescue the exception when the logout link is not found #39

jgrevich opened this issue Jul 8, 2021 · 2 comments
Labels
bug Something isn't working

Comments

@jgrevich
Copy link
Contributor

jgrevich commented Jul 8, 2021

When the logout link is found we get the following error:

[2021-07-07 20:31:19,311] j13/ERROR/locust.user.task: argument of type 'NoneType' is not iterable
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/site-packages/locust/user/task.py", line 290, in run
    self.execute_next_task()
  File "/usr/local/lib/python3.9/site-packages/locust/user/task.py", line 315, in execute_next_task
    self.execute_task(self._task_queue.pop(0))
  File "/usr/local/lib/python3.9/site-packages/locust/user/task.py", line 327, in execute_task
    task(self)
  File "/Users/jjg/Documents/sources/login/identity-loadtest/load_testing/sp_sign_in.locustfile.py", line 9, in sp_sign_in_load_test
    flow_sp_sign_in.do_sign_in(self)
  File "/Users/jjg/Documents/sources/login/identity-loadtest/load_testing/common_flows/flow_sp_sign_in.py", line 136, in do_sign_in
    logout_link = sp_signout_link(resp)
  File "/Users/jjg/Documents/sources/login/identity-loadtest/load_testing/common_flows/flow_helper.py", line 164, in sp_signout_link
    if "/logout" not in href:
TypeError: argument of type 'NoneType' is not iterable

We should rescue from that exception so that locust can record that as a failure.

We ran into this issue before: https://gsa-tts.slack.com/archives/C010L0SE4E8/p1586795114166400

@jgrevich
Copy link
Contributor Author

jgrevich commented Jul 8, 2021

While investigating this issue I noticed that the user lands here in the failed state:

Your login credentials were used in another browser. Please sign in again to continue in this browser.

Screen Shot 2021-07-08 at 3 15 43 PM

Related to https://github.com/18F/identity-devops/issues/3596 since this is likely happening due to the reuse of test users

@jgrevich jgrevich added the bug Something isn't working label Jul 8, 2021
@jgrevich
Copy link
Contributor Author

jgrevich commented Feb 1, 2023

Ditto for
Screen Shot 2023-02-01 at 2 27 00 PM

And the exceptions that occur when a worker is overloaded, and a test user is stuck waiting on IAL for > 60s: https://github.com/18F/identity-loadtest/blob/main/load_testing/lib/flow_sp_ial2_sign_up.py#L321-L336

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant