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

Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/engine.rb:201:in `kill': Invalid argument (Errno::EINVAL) #797

Open
Milella opened this issue Nov 28, 2023 · 0 comments

Comments

@Milella
Copy link

Milella commented Nov 28, 2023

On Windows 10, Ruby 3.2.2 Rails 7+ using Git Bash using Windows Terminal.
Foreman 0.87.2 when you hit Ctrl-C to break out of it will 100% of the time on Windows 10 with Rails 7+ (not sure if version of Ruby is effecting it or the v of rails) will give you an error message: In addition I tested this on 3 different Windows 10 machines, 1 of which was FRESHLY LOADED.

This is the error message you get:

C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/engine.rb:201:in `kill': Invalid argument (Errno::EINVAL)

Here is the full error log:
08:22:06 mailers.1 | 2023-11-28T16:22:06.354Z pid=31748 tid=beo INFO: Redis is online, 3.851824299999862 sec downtime
08:22:06 mailers.1 | 2023-11-28T16:22:06.354Z pid=31748 tid=bcg INFO: Redis is online, 3.8512884999945527 sec downtime
09:35:04 system | SIGINT received, starting shutdown
09:35:05 system | sending SIGTERM to all processes
C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/engine.rb:201:in kill': Invalid argument (Errno::EINVAL) from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/engine.rb:201:in kill_children'
from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/engine.rb:473:in terminate_gracefully' from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/engine.rb:439:in wait_for_shutdown_or_child_termination'
from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/engine.rb:60:in start' from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/cli.rb:42:in start'
from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/vendor/thor/lib/thor/command.rb:27:in run' from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/vendor/thor/lib/thor/invocation.rb:126:in invoke_command'
from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/vendor/thor/lib/thor.rb:369:in dispatch' from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/lib/foreman/vendor/thor/lib/thor/base.rb:444:in start'
from C:/ruby/Ruby32-x64/lib/ruby/gems/3.2.0/gems/foreman-0.87.2/bin/foreman:7:in <top (required)>' from C:/ruby/Ruby32-x64/bin/foreman:32:in load'
from C:/ruby/Ruby32-x64/bin/foreman:32:in `

'

Not only does it crash like I illustrated above it breaks the Bash session you are in, the next command you type no matter what it is ls, clear doesn't matter the Bash shell HANGS TIGHT and you have to end the task (also reproduced on all 3 machines). You can't even use the arrow keys in that Bash shell after the crash because it will do this for example if I try to click the up arrow to repeat the last command: ( I hit it about 7 or 8 times maybe)

scottm@RED-IT-LAP-0001 MINGW64 /d/dev/rails/stechit (main)
$ ^[[A^[[A^[[A^[[A^[[A^[[A^[[A^[[A

Now if I hit the up arrow normally it will bring up the last command but once this crash occurs again the Bash Shell becomes un-useable and must be closed which is a royal pain as when you develop you end up having to restart you app a lot.

I went back and tried an older app I had using the very same version of Foreman on Rails 6 on Ruby 2.7.8 and it still works but for some reason the way it looks is quite different. On the Rails 7 app foreman is in color where the older app even though it is the very same version of the gem is in monochrome instead of color, not sure why that is or if it is even related in any way just trying to think of any additional information I can to help.

I have tried starting foreman using foreman start vs the bin/dev and it ends up crashing the same way with the ctrl-c.

If there is anything additional I can provide to help please let me know. I have tried all of the normal troubleshooting such as removing and re-installing the foreman gem same results.

Thank you in advance for your help,
Scott

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

1 participant