I don't think your network issue is related to Safari. Try using nc:
$ nc localhost 3000 GET / < response from catalyst >This cuts out HTTP/1.1 and any other "overhead" that a real web browser adds. I bet, though, that this hangs too. Try running under the profiler:
$ perl -d:DProf script/myapp_server.plIf you manage to get good profile data, you should see one sub taking a lot of "real" time, and then you know where the bug is.
Unfortunately, DProf *loses data* if you kill the program with C-c, so this might not help detect the hang at all. There are apparently other profilers, but none of those work with Catalyst:
$ perl -d:Profile script/blog_server.pl Died at /usr/lib/perl5/site_perl/5.8/Template/Timer.pm line 63.Compilation failed in require at /usr/lib/perl5/site_perl/5.8/Catalyst/View/TT.pm line 6. BEGIN failed--compilation aborted at /usr/lib/perl5/site_perl/5.8/Catalyst/View/TT.pm line 6. Compilation failed in require at (eval 51)[/usr/lib/perl5/5.8/base.pm:82] line 3.
...propagated at /usr/lib/perl5/5.8/base.pm line 85.
BEGIN failed--compilation aborted at /cygdrive/c/Documents and
Settings/jrockway/blog_software/scrip
t/../lib/Blog/View/HTML.pm line 4.Compilation failed in require at (eval 50)[/usr/lib/perl5/site_perl/5.8/Catalyst/Utils.pm:252] line
3. Compilation failed in require at script/blog_server.pl line 52. :)DProf doesn't work for me either, because Math::Pari is very broken and DProf agitates its brokenness. *sigh* again :)
(BTW, sorry my first few posts to the list are so cynical. It's just that I spend a good precentage of my life with Catalyst and Perl so I've obviously had a chance to discover weird corner cases that cause annoyance. Actually, none of the bugs are Catalyst bugs, they're TT or Crypt::OpenPGP/Crypt::Random/Math::Pari bugs. Glad to know they're software bugs and not user error on my part, though. :)
Anyway, hope this helps somewhat. :) Regards, Jonathan Rockway apv wrote:
Hmmm. I'm not using CGI (it hangs on the most minimal install/welcome-page) and I have the most recent regular TT2 release.I'm glad you mention it though b/c I did have the problem you list with another TT2 form (not in Catalyst) and I found on antoher list that naming the CGI instance or calling it with a namespace fixed the hanging. [% USE CGI(foo) %] or [% USE mycgi = CGI(foo) %].http://www.template-toolkit.org/pipermail/templates/2002-May/003242.htmlI wrote a chat server about 4 years ago that had the same problem of hanging on Safari but not on the others. I can't remember how I solved it now but there was something different about the way Safari handled the socket blocking on reads between headers and body, I think. I'll try to dig up that code and compare it to the test server code.-Ashley
signature.asc
Description: OpenPGP digital signature
_______________________________________________ List: [email protected] Listinfo: http://lists.rawmode.org/mailman/listinfo/catalyst Searchable archive: http://www.mail-archive.com/[email protected]/ Dev site: http://dev.catalyst.perl.org/
