Project

General

Profile

Feature #14276

Updated by dsferreira (Daniel Ferreira) over 6 years ago

I would like to propose the creation of a ruby core minimal API for a Debugger. 

 Historically we have been relying on gems as providers of debug functionality. 
 This has caused problems with debugger APIs being broken and the debugger gems being outdated by ruby releases. 
 This happened in the transitions from 1.8.* to 1.9.* and 1.9.* to 2.** 

 Currently ruby community relies mostly on *byebug* gem (+ pry) for debugging purposes. 

 Recently a new bug [14226](https://bugs.ruby-lang.org/issues/14226) was raised due to changes in ruby internals that broke *byebug*. 

 I consider that the debugger should be a core part of a language like ruby. 
 Developing production code without an available debugger is not very manageable. 

 For this reason I believe we should have a way of guaranteeing that each ruby release will not break the debugger. 

 Also having full control of the debugger API is very convenient for future purposes. 
 This way third party entities can rely on it to develop productivity tools. 

 I see two ways we can accomplish this: 

 - Defining core Debug API namespace where we would create the minimal interface for ruby core debug functionality (Not sure if only cruby or a broader API adopted and designed in collaboration with the other ruby implementations). 
 - Creating debug gem in standard lib with the same purpose. Having the guarantee that the unit tests will run for every ruby release. 

 The main goal in my mind would be to have a bare minimum (TDD?) TDD development environment available upon ruby installation 
 with each bare minimum API providing the base functionality to allow the development of full fledged solutions capable of rivaling with the best solutions in the market. 
 For that goal I would include here for consideration the same approach for other functionalities such as: 
 * Coverage 
 * Documentation 
 * Benchmarks 
 * Tests 
 * Performance 
 * Linter 
 * ? 

 I believe we have currently a good situation with regards to: 
 - Documentation (Rdoc) 
 - Tests (Minitest) 

 Why not try to replicate those examples for the remaining areas? 
 Are documentation and tests so much different from the rest? 

 If we succeeded to do that we could present ruby to the new comer with a simpler development environment easing the entry level. 
 We could put simple documentation in ruby-lang.org to show how to achieve a professional development workflow with ruby with no fuss. 

 A full TDD environment available upon installation it is a great marketing headline in my perspective. 

 Just to finalise. 
 The goal here is not to have ruby core replacing the existing gems. 
 The goal is to give a clear path for these gems while allowing others to develop even further in top of a sound base 
 without worries regarding future support on the APIs being used. 

Back