Issue #1 on hold

AttributeError: 'float' object has no attribute 'replace'

lokkju
created an issue

This only should affect sqlite with it's poor type checking on columns. Small bug - looks like values are always being passed to cgi.escape, even if not a string. Easiest may be to always convert to string? not sure if there would be any performance impact.

{{{ Traceback (most recent call last): File "/usr/local/lib/python2.6/dist-packages/gevent-0.13.0-py2.6-linux-i686.egg/gevent/wsgi.py", line 109, in handle self.data.extend(result) File "/data/sites/htsql/src/htsql/application.py", line 83, in call body = wsgi(environ, start_response) File "/data/sites/htsql/src/htsql/wsgi.py", line 44, in call status, headers, body = request.render(environ) File "/data/sites/htsql/src/htsql/request.py", line 156, in render return renderer.render(product) File "/data/sites/htsql/src/htsql/fmt/html.py", line 30, in render body = list(self.generate_body(product)) File "/data/sites/htsql/src/htsql/fmt/html.py", line 77, in generate_body for chunk in self.serialize_html(product): File "/data/sites/htsql/src/htsql/fmt/html.py", line 90, in serialize_html for chunk in self.serialize_body(product): File "/data/sites/htsql/src/htsql/fmt/html.py", line 151, in serialize_body for chunk in self.serialize_content(product): File "/data/sites/htsql/src/htsql/fmt/html.py", line 202, in serialize_content output = format(value) File "/data/sites/htsql/src/htsql/fmt/html.py", line 267, in call return cgi.escape(value) File "/usr/lib/python2.6/cgi.py", line 1035, in escape s = s.replace("&", "&amp;") # Must be done first! AttributeError: 'float' object has no attribute 'replace' <WSGIServer fileno=3 address=0.0.0.0:8088>: Failed to handle request: request = <http_request "GET /zoning.limit(50) HTTP/1.1" 127.0.0.1:34905> application = <htsql.application.Application object at 0xb714a90c> }}}

Comments (4)

  1. Log in to comment