-
-
Notifications
You must be signed in to change notification settings - Fork 327
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
When use byebug
and continue
once, Ruby process get slow.
#144
Comments
@kntmrkm Cool, thanks. I had an idea on how to improve this. I'll disable the debugger when user hits |
We're also experiencing this issue. We are using puma, but otherwise basically the same setup and symptom. |
Same problem here. Page load time increase substantially after debugger is hit. If I remove the byebug call from the code and refresh the page, it still runs slow. Only way to resolve is to stop and restart rails. |
I've also been seeing the behavior described by @choltz-i4cp . I've tried byebug 3.1.2, 4.0.5 and even 5.0 but the bug is present in all of these versions. |
Yep, same for me. The only remedy is a full server restart. |
Same issue |
+1 |
1 similar comment
+1 |
Ignoring this thread until I get to it. |
@deivid-rodriguez perhaps you share your idea? You said earlier "I had an idea on how to improve this", so perhaps one of us can work off of that idea and speed up a solution for this issue. |
Already did, read the next sentence after the one you quoted. |
Ah gotcha. I interpreted that as a workaround until you get to your idea. Thanks for the pointer. |
👍 |
This is due to the Puma worker process (even if workers are disabled) and I've linked a previous discussion. It may be that the debugger is leaving content in the STDIN buffer or something as there was recently a fix added to Puma to try to remedy this situation. If you look at your startup log and the processes you'll see the worker hit ~ 100% CPU. |
The issue is not isolated to Puma. I've seen it on thin and webrick as well. |
Yes, this has nothing to do with Puma. It's an issue with |
Oh right, no problems :) We just were not seeing this on Unicorn or the standard Rails console, only with Puma. |
version 6.0 resolved this problem. |
deivid-rodriguez/pry-byebug#61 is still unresolved until pry-byebug depends on byebug 6 |
😮 There has not been any (intentional) fixes regarding this issue in this release... |
@naw The work to support byebug 6 is already done here: https://github.com/deivid-rodriguez/pry-byebug/tree/support_latest_byebug |
OK I forked here: https://github.com/naw/pry-byebug/tree/support_latest_byebug and pointed my app at it. Request initially around 1800ms, but after a single So, I'm afraid I'll have to disagree with @kntmrkm regarding whether this issue is resolved, at least when using |
Also not fixed for me with 6.0
If I go back to byebug 3.5.1 (what I used before upgrading to 5 and then 6), I still have this problem but it isn't quite as bad
Ruby 2.2.0p0, x86_64-darwin-14 |
The comparison to |
byebug + pry == slow dev env. Source: deivid-rodriguez/byebug#144
byebug + pry == slow dev env. Source: deivid-rodriguez/byebug#144
@deivid-rodriguez any fix for this? |
@JacksonGariety fixed on #160 a while ago: |
@fbernier thanks but this still seems to be an issue on 9.0.3 |
@JacksonGariety Can you share some numbers? This issue seems closed for most people... |
Can confirm this is an issue. I use byebug + sublime debugger and they work super slow. |
@deivid-rodriguez rails says |
Running Byebug 9.0.6 on Rails 5.0.0.1 (Ruby 2.3.0p0), and as soon as I enable it, my page load times increase dramatically. Before:
After:
I'm not using any |
How do you enable the debugger without using the |
Ah, I should've mentioned. I'm using this initializer for remote debugging while using Unicorn as an application server: if Rails.env.development?
require 'byebug/core'
Byebug.start_server 'localhost', 3001
end I'm not sure if I've missed anything obvious… is there another way to make Byebug work with other app servers other than remote debugging like this? |
Nope, it's ok. So I guess that's it, this was fixed for local debugging but probably not for remote debugging. |
@deivid-rodriguez Found this issue and so happy that solution works for me 😃 UPD I use |
Also seems like |
Any workaround for remote debugging? |
Closing again in favor of #302. |
This still exists with local development using byebug (9.0.6) and simple Before
After
|
This is happening for me locally using Test App (Fresh with one view and controller action):
Real App (API call returning JSON):
Restarting the server is the only way I can remedy it. I ended up going back to |
Hi @trcarden and @jmyers0022, can you help me out reproducing your problems? I tried the following. Add a Can you tell me the exact steps you take to experience this issue? |
I have the same issue with version |
After use
byebug
andcontinue
.Page load time get slow. Webrick's ruby process got slow maybe.
Before use
byebug
After use
Gemfile is just
I've open issue at
pry-byebug
, but This relate tobyebug
maybe.This is linked this issue.
deivid-rodriguez/pry-byebug#61 (comment)
The text was updated successfully, but these errors were encountered: