I’ve just started going through the first edition of Agile Web
Development with Rails on my Mac running a near stock install of 10.4.8.
The very first example in the book (page 28) involves running an
unmodified generated application (just “rails foo” on the command line,
and then “scripts/server” to start WEBrick). The application builds
fine, and it works perfectly in Firefox, but it doesn’t work in Safari.
In Safari, I get the following:
500 Server Error
[code=CANT_CONNECT_LOOPBACK] Cannot connect due to potential loopback
problems.
On Safari, these all result in the aforementioned 500 error.
So it seems like my ruby application and my WEBrick server are all
working perfectly. Something that Safari does differently than Firefox
is causing the error. Proxy settings, host files, etc? I haven’t
knowingly made any changes to these. This is using ruby 1.8.2 that
comes with Mac OS 10.4 and the latest Ruby Gems package. I’ve also
installed the readline upgrade but that didn’t fix the problem.
On Safari, these all result in the aforementioned 500 error.
So it seems like my ruby application and my WEBrick server are all
working perfectly. Something that Safari does differently than Firefox
is causing the error. Proxy settings, host files, etc? I haven’t
knowingly made any changes to these. This is using ruby 1.8.2 that
comes with Mac OS 10.4 and the latest Ruby Gems package. I’ve also
installed the readline upgrade but that didn’t fix the problem.
Yeah, this is definitely a networking problem, nothing to do with
Rails/Ruby. Try disconnecting from the internet and/or your local
wired/wireless network, and see if it works then.
Unfortunatley, when I re-enable the ethernet connection, the old 500
problem comes back. Does anyone know why this would happen and what a
more workable solution would be?
My only thought is that I’ve inadvertently made a change to some
networking configuration file somewhere. Is there a good way to reset
my network to its original state without resorting to an OS reinstall?
Is Automatic Proxy Configuration turned on (in Network preferences, for
your Ethernet connection, under Proxies, in the list of ‘proxy servers
to configure’)? If so, try turning it off.
Is Automatic Proxy Configuration turned on (in Network preferences, for
your Ethernet connection, under Proxies, in the list of ‘proxy servers
to configure’)? If so, try turning it off.
Yeah, this is definitely a networking problem, nothing to do with
Rails/Ruby. Try disconnecting from the internet and/or your local
wired/wireless network, and see if it works then.
My internet setup is just a cable modem with an ethernet connection to
my machine. When I disable the ethernet connection, the ruby
application begins to work perfectly in Safari. Thanks very much Chris!
Unfortunatley, when I re-enable the ethernet connection, the old 500
problem comes back. Does anyone know why this would happen and what a
more workable solution would be?
My only thought is that I’ve inadvertently made a change to some
networking configuration file somewhere. Is there a good way to reset
my network to its original state without resorting to an OS reinstall?
This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.