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

Stuck at cpu 100% #121

Closed
la-ruby opened this issue Nov 19, 2019 · 6 comments
Closed

Stuck at cpu 100% #121

la-ruby opened this issue Nov 19, 2019 · 6 comments

Comments

@la-ruby
Copy link

la-ruby commented Nov 19, 2019

Basically when using robe (sometimes) emacs is unresponsive and I see ruby nearly using up all the cpu.

Screen Shot 2019-11-18 at 6 19 23 PM

@dgutov
Copy link
Owner

dgutov commented Nov 19, 2019

Can you see which request spins up all this CPU usage?

Robe creates access log files in /tmp/robe-access-xxxx.log, you can look for the most recent one.

@la-ruby
Copy link
Author

la-ruby commented Nov 22, 2019

It took a few days, but finally it happened again:

I, [2019-11-21T19:00:44.143674 #10825]  INFO -- : GET /ping/
I, [2019-11-21T19:00:44.150789 #10825]  INFO -- : GET /load_path/
I, [2019-11-21T19:00:44.155896 #10825]  INFO -- : GET /method_targets/new/DummyClass/HubshoplyBigcommerceTest/-/-/-

Screen Shot 2019-11-21 at 7 01 15 PM

Cursor is at position shown in screenshot, and last thing I did was press "C-c C-d"

oh btw i not sure if its because I'm on macos beta 2, but the log file isn't where you think it is ( /System/Volumes/Data/private/var/folders/w2/htjjxxl52ssdll1yhyz1t7380000gn/T )

@dgutov
Copy link
Owner

dgutov commented Nov 22, 2019

Thanks!

Cursor is at position shown in screenshot, and last thing I did was press "C-c C-d"

So what happens if you restart Emacs, etc, and the do the same thing at the same position? Does it freeze immediately as well? In other words, is the problem easy to reproduce?

oh btw i not sure if its because I'm on macos beta 2, but the log file isn't where you think it is ( /System/Volumes/Data/private/var/folders/w2/htjjxxl52ssdll1yhyz1t7380000gn/T )

That's fine, I really have no idea which directories macOS uses for tmp storage.

@dgutov
Copy link
Owner

dgutov commented Jun 12, 2020

Another thing to try is to install https://github.com/rbspy/rbspy.

When (if!) this happens again, you can ps aux | grep ruby, find the process pid, and then output its current backtrace: sudo rbspy snapshot --pid <pid>.

@dgutov
Copy link
Owner

dgutov commented Jul 30, 2020

Anyway, I have fixed a similar behavior recently (#105).

Here's hoping it took care of this case as well.

If it happens again, let me know.

@dgutov dgutov closed this as completed Jul 30, 2020
@la-ruby
Copy link
Author

la-ruby commented Jul 30, 2020

I was reading the emacs Changelog last week and was pleasantly surprised to see your name - its great a ruby developer playing an active role in the emacs core, keep up the good work! @dgutov

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

No branches or pull requests

2 participants