Comments (6)
More concisely, what happens with ruby-2.0/debase-0.0.3 is that every time the thread hits a breakpoint and suspends, debase reports back first 'suspend' then 'breakpoint' for the same line. Whereas ruby-1.9/ruby-debug-base19x always reports exactly one event: if the thread was running and it hits a breakpoint, it reports only 'breakpoint'; if the thread was being stepped and the step finishes, it reports 'suspend'.
This confuses the Netbeans plugin because it only ever expects only one event when the thread suspends - it treats the 'breakpoint' and 'suspend' events exactly the same. So it ends up locking a semaphore twice for essentially what is the same event, and when the user issues a command to step or continue, it only releases the semaphore once and subsequently freezes.
from debase.
If I comment out this line in debase's ext/debase_internals.c#process_line_event function:
rb_funcall(context_object, idAtBreakpoint, 1, breakpoint);
the ruby-netbeans plugin runs without problem.
This makes debase only send suspend events, ie it never sends breakpoint events, so it doesn't exactly mimic the behaviour of ruby-debug-base19x. So the question still is, should debase mimic ruby-debug-base19x's behaviour? Modifying the ruby-netbeans plugin to handle the current debase-0.0.3 behaviour is a bit complex unless we change it to just ignore all breakpoint events from any version of ruby greater than 1.9.
from debase.
Yes, it looks like behaviour is slightly different compared with ruby-debug-base19x. I'll test version with commented breakpoint event on RubyMine and will upload it if everything is ok
from debase.
How did it go in RubyMine?
from debase.
The real problem was in debase not setting correct stop reason when hitting breakpoint. You can try debase-0.0.4, it should work ok now.
from debase.
Thanks, debase-0.0.4 does work now in Netbeans.
from debase.
Related Issues (20)
- migrate tests to GHA HOT 1
- Debase gem not installing on MacOS Ventura and M1 HOT 2
- Debase failing to install on vscode Jekyll container HOT 1
- Failed to install in ruby docker image (vm_insnhelper.h missing) HOT 2
- Symbol not found: _rb_cObject on M1 Mac HOT 1
- Failed to install debase on Windows 10: is the new version for ruby-3.2.2 not releasing yet? HOT 3
- Can't install on mac os arm Mac OS Sonoma 14.4 HOT 9
- INTERNAL ERROR!!! ArgumentError: wrong number of arguments (given 2, expected 1)
- Ruby 2.7.1 compatibility HOT 4
- Won't install with ruby 2.6.6 on macOS Big Sur HOT 12
- ERROR: Failed to build gem native extension - Mac(Catalina)+RVM(ruby 2.5.8) HOT 5
- 0.2.4.1 and 0.2.5.beta Fail to build on macOS Catalina 10.15.7 HOT 15
- Ruby 3.0.0 compatibilty HOT 10
- Missing tags for 0.2.4 and 0.2.4.1 release HOT 1
- Ruby 3.0.2 compatibilty HOT 11
- Ruby 3.1 compatibility issue HOT 5
- Debugger stops only on 1st breakpoint inside a Fiber block and ignores all subsequent ones
- debase failing to install on Mac HOT 1
- Failed to install Debase HOT 7
- Debbuger steps into internal kernel in ruby 3.x
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from debase.