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

fix: kill all server-related processes on test session end #277

Closed
wants to merge 1 commit into from
Closed

fix: kill all server-related processes on test session end #277

wants to merge 1 commit into from

Conversation

guilefoylegaurav
Copy link
Contributor

@guilefoylegaurav guilefoylegaurav commented Sep 5, 2022

Description

This PR fixes #249

Changes

  • replace process.terminate() with os.killpg(). The former does not kill child processes spawned, while the latter does.
  • scope pytest fixtures to session level
  • use os.killpg() (POSIX) or process.kill() (non-POSIX) as per host OS

Documentation

  • No documentation update is required

How I've tested my work

  • Passed 25/25 tests on running pytest inside integration_tests/ (Debian 10)

  • Pending:

    • Windows: Passed 23/25 tests on running pytest inside integration_tests/
      • Reason: On test_global_index_request and test_dev_index_request() python3 invoked in shell instead of python - for Windows versions of Python (i.e. not WSL), python3 is not typically a standard alias

@netlify
Copy link

netlify bot commented Sep 5, 2022

Deploy Preview for robyn canceled.

Name Link
🔨 Latest commit d66d508
🔍 Latest deploy log https://app.netlify.com/sites/robyn/deploys/63163fffb911260008e6bdce

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.

[BUG] The --dev mode spawns more servers without clearing previous ones.
1 participant