-
-
Notifications
You must be signed in to change notification settings - Fork 27
[BUG] breaks with foreman and rails #46
Comments
Hi guys, thanks for reporting this issue. The root cause of this isuse is that foreman redirects the STDOUT of the rails server (or any proc program) into a pipe (found at https://github.com/ddollar/foreman/blob/5b815c5d8077511664a712aca90b070229ca6413/lib/foreman/engine.rb#L367). Ruby Jard depends heavily on the STDOUT of the program to create rich user interfaces inside terminal, and the STDOUT is a TTY is important. So, any redirection prevents Jard from doing its job. Similar situations happen with other TUI apps like The most completed way to overcome this is remote debugging. Unfortunately, it's not available now. It's definitely in my roadmap at https://rubyjard.org/docs/roadmap/. I'll make it higher priority since I see some ues cases for it recently. In the mean time, you could run the process you want to debug outsie of foreman. Besides, jard should return a more meaningful message (Jard could not work with redirected STDIN/STDOUT for example), instead of throwing a confusing backtrace like above. Btw, there was a related conflict between byebug and foreman: ddollar/foreman#58 |
Hi @jtmkrueger, @calebmeyer. Please ignore my above post. During the night, I finally found a way to make Jard works with standard stream redirection, which is trying to find the real user tty from I'll do some manual tests, and wait for other bug fixes before I can release a new version. In the meantime, you guys can test it out by pointing to the master branch: gem 'ruby_jard', group: :development, git: 'https://github.com/nguyenquangminh0711/ruby_jard' |
Whoa, I was not expecting this to work. I thought requiring a user to run as |
Describe the bug
When I try to run with foreman, it errors out
To Reproduce
Steps to reproduce the behavior:
jard
breakpoint in a rails applicationforeman
Expected behavior
The jard window to pop up somwhere
here's the stack trace in a gist
Environment (please complete the following information):
tput colors
in your terminalecho $TERM
in your terminalstty
The text was updated successfully, but these errors were encountered: