From: Dean M. C. B. <dmb...@fr...> - 2008-09-02 12:35:01
|
Hi Kim, > -----Original Message----- > From: cpp...@li... > [mailto:cpp...@li...] On > Behalf Of Kim Gräsman > Sent: Tuesday, September 02, 2008 8:27 PM > To: C++ Networking Library Developers Mailing List > Subject: [cpp-netlib-devel] localhost_tests failures > > Hi guys, > > The localhost_tests suite is failing for me, out of the box, > with the following: > > -- > Running 12 test cases... > libs/network/test/localhost_tests.cpp(190): error in > "text_file_query": check body(response_).length() == size failed [113 > != 117] > libs/network/test/localhost_tests.cpp(260): fatal error in > "cgi_query": exception thrown by r = c.get(req) > libs/network/test/localhost_tests.cpp(271): fatal error in > "cgi_multi_line_headers": exception thrown by r = c.get(req) > > *** 3 failures detected in test suite "http 1.0 localhost tests" > -- > > This is on Windows XP SP2, VC 9.0 (no service pack), Boost 1.37 > (straight from the SVN trunk) and Python 2.5.2. > > I haven't investigated the latter two closely (it appears they aren't > getting any body whatsoever), but the first one is strange. The file > size of test.xml, according to Windows Explorer, is 117 bytes, but the > Python script is only serving 113 bytes (I checked this with Firefox > as a client as well). > The issue has something to do with Python bugs that Divye has posted to the list earlier. There's currently no workaround for this, since we haven't been implementing an HTTP Server in the library yet. At any rate, this doesn't manifest itself in Linux. > So... I'm not sure where it's going wrong. Any ideas on where to start > looking? It looks like it might be some kind of encoding mismatch, > perhaps? > Currently there's no encoding handling that goes on in cpp-netlib -- we deal with raw bytes that come from the wire, which we treat as character buffers. Like I mentioned already, it's a Python in Windows bug. ;) > Also, there seems to be a race condition where the tests occasionally > launch before Python has had a chance to start, but I think that may > be solvable by extracting the server start out into a global fixture > (something I'm working on here -- patch coming). > Looking forward to the patch. :) HTH -- Dean Michael Berris Software Engineer, Friendster, Inc. |