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: prevent infinite loop by adding break statement in example ping.py #493

Merged
merged 2 commits into from
Jan 1, 2025

Conversation

acul71
Copy link
Contributor

@acul71 acul71 commented Jan 1, 2025

What was wrong?

Issue #492 Enhancement of the ping.py example to improve performance and clarity. The issue addressed high GIL contention in the handle_ping function

How was it fixed?

Adding a missing break statement
These changes lowered the GIL usage to between 0%-2%, a significant improvement over the original implementation.

To-Do

  • Clean up commit history

Cute Animal Picture

put a cute animal picture link inside the parentheses

@pacrob pacrob merged commit bc90632 into libp2p:main Jan 1, 2025
17 checks passed
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