Problem with cgi module and pypy handling POST request

Hi, I got the following error playing with pypy 5.9.0 under my linux32 development server: Traceback (most recent call last): File "/home/erob/src/django-hotsauce-0.9.1/lib/notmm/controllers/base.py", line 195, in get_response response = callback(request, *args, **kwargs) File "/home/erob/src/django-hotsauce-stable/extras/libauthkit/authkit/authorize/decorators.py", line 67, in _wrapper return view_func(request, **kwargs) File "/home/erob/src/django-hotsauce-0.9.1/lib/notmm/dbapi/orm/decorators.py", line 35, in _wrapper return view_func(req, **kwargs) File "/home/erob/src/blogengine2-devel/lib/blogengine2/views/category.py", line 57, in add new_data = request.POST.copy() File "/usr/local/pypy/pypy2-v5.9.0-linux32/site-packages/werkzeug/local.py", line 347, in __getattr__ return getattr(self._get_current_object(), name) File "/home/erob/src/django-hotsauce-0.9.1/lib/notmm/utils/wsgilib/request.py", line 96, in POST return self.get_POST() File "/home/erob/src/django-hotsauce-0.9.1/lib/notmm/utils/wsgilib/request.py", line 69, in get_POST keep_blank_values=True) File "/usr/local/pypy/pypy2-v5.9.0-linux32/lib-python/2.7/cgi.py", line 507, in __init__ self.read_multi(environ, keep_blank_values, strict_parsing) File "/usr/local/pypy/pypy2-v5.9.0-linux32/lib-python/2.7/cgi.py", line 631, in read_multi environ, keep_blank_values, strict_parsing) File "/usr/local/pypy/pypy2-v5.9.0-linux32/lib-python/2.7/cgi.py", line 509, in __init__ self.read_single() File "/usr/local/pypy/pypy2-v5.9.0-linux32/lib-python/2.7/cgi.py", line 646, in read_single self.read_lines() File "/usr/local/pypy/pypy2-v5.9.0-linux32/lib-python/2.7/cgi.py", line 668, in read_lines self.read_lines_to_outerboundary() File "/usr/local/pypy/pypy2-v5.9.0-linux32/lib-python/2.7/cgi.py", line 696, in read_lines_to_outerboundary line = self.fp.readline(1<<16) TypeError: readline() takes exactly 1 argument (2 given) Any ideas how to fix this issue? Thank you in advance, Etienne https://www.isotopesoftware.ca

The output is: <wsgiref.validate.InputWrapper instance at 0xb3e1c784> I also managed to fix this issue by removing the "1<<16" parameter in self.fp.readline(). Regards, Etienne Le 2018-03-26 à 11:04, Matti Picus a écrit :
-- Etienne Robillard tkadm30@yandex.com https://www.isotopesoftware.ca/

Le 2018-03-26 à 13:55, Matti Picus a écrit :
Sorry, but without my patch I cannot make PyPy 5.9.0 to handle a POST request. Could you please suggest any other fix? Etienne -- Etienne Robillard tkadm30@yandex.com https://www.isotopesoftware.ca/

The output is: <wsgiref.validate.InputWrapper instance at 0xb3e1c784> I also managed to fix this issue by removing the "1<<16" parameter in self.fp.readline(). Regards, Etienne Le 2018-03-26 à 11:04, Matti Picus a écrit :
-- Etienne Robillard tkadm30@yandex.com https://www.isotopesoftware.ca/

Le 2018-03-26 à 13:55, Matti Picus a écrit :
Sorry, but without my patch I cannot make PyPy 5.9.0 to handle a POST request. Could you please suggest any other fix? Etienne -- Etienne Robillard tkadm30@yandex.com https://www.isotopesoftware.ca/
participants (2)
-
Etienne Robillard
-
Matti Picus