oneclick / rubyinstaller2

MSYS2 based RubyInstaller for Windows
https://rubyinstaller.org
BSD 3-Clause "New" or "Revised" License
644 stars 248 forks source link

Ruby 3.3.0 - Rails 7.1.3 - Windows 11 Pro #370

Open charlie-prezzano opened 5 months ago

charlie-prezzano commented 5 months ago

What problems are you experiencing?

Rails server starts, but exits with no stacktrace / messages when first web page loads.

I use RubyMine, but starting the rails sever via command line to remove the it as a variable.

Start the server ...

PS C:\Users\hawth\RubymineProjects\project-name> rails server -b 127.0.0.3 -p 3000 -e development                
C:/Users/hawth/.local/share/gem/ruby/3.3.0/gems/zeitwerk-2.6.12/lib/zeitwerk/kernel.rb:38: warning: csv was loaded from the standard library, but will no longer be part of the default gems since Ruby 3.4.0. Add csv to your Gemfile or gemspec. Also contact author of zeitwerk-2.6.12 to add csv into its gemspec.
=> Booting Puma
=> Rails 7.1.3 application starting in development
=> Run `bin/rails server --help` for more startup options
*** SIGUSR2 not implemented, signal based restart unavailable!
*** SIGUSR1 not implemented, signal based restart unavailable!
*** SIGHUP not implemented, signal based logs reopening unavailable!
Puma starting in single mode...
* Puma version: 6.4.2 (ruby 3.3.0-p0) ("The Eagle of Durango")
*  Min threads: 5
*  Max threads: 5
*  Environment: development
*          PID: 13812
* Listening on http://127.0.0.3:3000

Server successfully starts ... visit http://127.0.0.3:3000/:

Started GET "/" for 127.0.0.1 at 2024-02-05 13:23:59 -0500
  ActiveRecord::SchemaMigration Load (30.0ms)  SELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC
PS C:\Users\hawth\RubymineProjects\project-name> 

As there is no stack trace / messages this is tough to debug.

Two things to note:

MSP-Greg commented 5 months ago

@charlie-prezzano

This is probably a Rails or Puma issue. I am a Windows user and I'm also involved with Puma. Do you see anything in the browser?

charlie-prezzano commented 5 months ago

Thank you for the response @MSP-Greg.

There is no messages in the browser. The server immediately shuts down - the browser states that it cannot establish a connection.

Right, the issue could be with Rails or Puma. I did push the project to my Test environment on Heroku, and it loaded without issue. The joys of programming in Windows.

For now I'll stick with Ruby 3.2.2 and Rails 7.1.3, using Puma 6.4.2, Once I have a working environment with Ruby 3.3.X I'll report back.

MSP-Greg commented 5 months ago

For now I'll stick with Ruby 3.2.2 and Rails 7.1.3, using Puma 6.4.2, Once I have a working environment with Ruby 3.3.X I'll report back.

Just to confirm, the above works on Windows, but Ruby 3.3.0 does not?

Puma is testing against Windows 3.3 and also Windows Ruby head/master, and that works fine (locally, I usually test with Ruby head/master).

There are some Ruby ABI changes in 3.3.0, but I don't recall what they are. There may be an extension gem that isn't compatible with Ruby 3.3. Really not sure, and don't have much free time today.

charlie-prezzano commented 5 months ago

Correct ... Ruby 3.2.2 with Rails 7.1.3, using Puma 6.4.2, works on my Windows environment ... swapping in Ruby 3.3.0 fails.

mohits commented 5 months ago

hi @charlie-prezzano - I have done a basic scaffold app with Rails 7.1.3, Ruby 3.3.0, Puma 6.4.2 on Windows 10 Pro and it seems to start up and run.

By the way, I notice this in your command:

 server -b 127.0.0.3

but this in your GET

Started GET "/" for 127.0.0.1

Is it intentional that you're starting the server on 0.3 but doing a GET to 0.1?

charlie-prezzano commented 4 months ago

Hi @mohits. Thank you for the reply.

I'm unsure why the server ip does not match the get request ip. I updated the server to run on 127.0.0.1 and have the same issue.

In the next day or two I'm starting a new rails app and will see if that works.

mohits commented 4 months ago

Thanks for checking that, @charlie-prezzano. I just realised that I've always used 127.0.0.1. It's unfortunately now at a point for me that it works here and doesn't work for you. If you do find the solution, would you post here please? Thanks!

mohits commented 4 months ago

Hi @charlie-prezzano - did it work?

charlie-prezzano commented 4 months ago

I have not gotten this to work, so I have reverted back to Ruby 3.2 for now. Once the next minor version of Ruby 3.3 is released I will try again. It's not critical for me to upgrade, so I'll wait it out.