Line breakpoints aren't shared between processes
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 5/5
- Tempo estimado
- Mais de uma semana
- Facilidade para iniciantes
- 35/100
Direção de pesquisa
Reproduce the behavior with the Rails/Puma multi-process setup described in the issue, using five workers and line breakpoints. Then inspect the debugger's process handling mechanism; done means a line breakpoint added to one process stops requests handled by every process, with behavior checked in VSCode attach mode.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Your environment
ruby -v:3.1.0rdbg -v:1.6.0
Describe the bug
When the debuggee application has multiple processes, line breakpoints added to 1 of them won't be shared to other processes.
This will cause inconsistent breakpoint stop because only that process will stop and others won't.
To Reproduce
This issue should happen to any application that:
- Has multiple processes
- Uses line breakpoints
But reproducing it with VSCode is easier:
-
Create a new rails application
-
In
config/puma.rb, setthreads 1, 1 # limit the threads number to 1 will increase the reproduction chance # other configs workers 5 # increase this number will also help reproduction -
Start the server with
bundle exec rdbg -c -- bundle exec rails s -
Set a breakpoint
-
Attach the debugger
-
Sending requests to the Rails app
-
The breakpoint should stop at some requests but not all of them
Expected behavior
The breakpoints should stop at every request
Additional context
@ko1 mentioned that:
- Resolving this will require rewriting a big part of the process handling mechanism
- Possible workarounds: 1) Use only 1 process or 2) For VSCode users, use launch mode instead
- There are no timeline for this issue yet (probably not before Ruby 3.2 is out)
- Linguagem predominante
- Ruby
- Estrelas
- 1.3k
- Forks
- 146
- Métricas de merge de PRs
- Nenhum PR com merge em 30d
Guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de ruby/debug
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 68/100
-
Support exceptionOptions in setExceptionBreakpoints to catch arbitrary exception classes via DAP Aberta
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 55/100
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 45/100
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 52/100
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 35/100
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
palladius/rails8-app-on-gcp#145 ·
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
rubocop/rubocop-rspec#2236 ·
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
riscv/riscv-unified-db#2624 · 1 reação ·
-
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 88/100
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100