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

Gracefully shutdown the browser #423

Closed
ankur22 opened this issue Jun 28, 2022 · 2 comments · Fixed by #535
Closed

Gracefully shutdown the browser #423

ankur22 opened this issue Jun 28, 2022 · 2 comments · Fixed by #535
Assignees
Labels
bug Something isn't working
Milestone

Comments

@ankur22
Copy link
Collaborator

ankur22 commented Jun 28, 2022

It would seem that the context is being cancelled which is causing the browser processor to be killed instead of gracefully being shutdown. The plan is to follow the steps outlined below to see if in majority of cases we can correctly shutdown the browser process and avoid logging errors on cmd.wait().

Sounds good about the new issue. The context is cancelled after each iteration, besides the RunContext being cancelled at shutdown. So we should be able to stop the process gracefully here, and ensure it works when running with multiple VUs/iterations, even though we can't ensure that it will work when k6 is stopped abruptly or at test end because of #2432.

Originally posted by @imiric in #419 (comment)

@ankur22 ankur22 self-assigned this Jun 28, 2022
@ankur22 ankur22 added the bug Something isn't working label Jun 28, 2022
@ankur22 ankur22 added this to the v0.4.0 milestone Jun 28, 2022
@inancgumus
Copy link
Member

For reference: grafana/k6#2432 (comment)

@inancgumus inancgumus modified the milestones: v0.4.0, v0.5.0 Jun 30, 2022
@imiric imiric modified the milestones: v0.5.0, v0.6.0 Aug 18, 2022
imiric pushed a commit that referenced this issue Sep 16, 2022
This should be fixed now for regular iterations, so we don't need to
hide it anymore. #423 is still relevant for sudden exits with e.g. SIGINT,
but we should log that as an error if it happens.
@ankur22 ankur22 removed their assignment Sep 16, 2022
imiric pushed a commit that referenced this issue Sep 23, 2022
This should be fixed now for regular iterations, so we don't need to
hide it anymore. #423 is still relevant for sudden exits with e.g. SIGINT,
but we should log that as an error if it happens.
@imiric
Copy link
Contributor

imiric commented Sep 28, 2022

I think this is now fixed after #535 and can be closed, right? @grafana/k6browserdev

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

Successfully merging a pull request may close this issue.

4 participants