Commits

Justin Wilson committed a921a29

fixed small, typo, issue with exceptions

  • Participants
  • Parent commits f0ec119

Comments (0)

Files changed (6)

-gserver 0.1.5
+gserver 0.1.6
 =============
 
 Simple wrapper around `gevent`_ that provides a basic routing engine
 
 .. currentmodule:: gserver
 
+Release 0.1a6
+-------------
+
+*BugFix*  - Fixed http exceptions classes (copy and paste errors :S)
+
 Release 0.1a5
 -------------
 

gserver/__init__.py

 __copyright__	= "Copyright 2011, Justin Wilson"
 __credits__		= ["Justin Wilson", "Eber Irigoyen", "Corey McKinnon"]
 __license__		= "Simplified BSD License"
-__version__		= "0.1.5"
+__version__		= "0.1.6"
 __maintainer__	= "Justin Wilson"
 __email__		= "justinwilson1@gmail.com"
 __status__		= "Alpha"

gserver/exceptions.py

 class Http403(HttpError):
 	""" Exception used to respond with a 403, instead of a success and data """
 	def __init__(self):
-		super(Http404, self).__init__(403)
+		super(Http403, self).__init__(403)
 
 class Http404(HttpError):
 	""" Exception used to respond with a 404, instead of a success and data """
 class Http405(HttpError):
 	""" Exception used to respond with a 405, instead of a success and data """
 	def __init__(self):
-		super(Http404, self).__init__(405)
+		super(Http405, self).__init__(405)
 
 class ResponseStartedError(Exception):
 	""" Exceptions used to indicate that a response has already been started

gserver/request.py

 		query_data		= parse_qs(env.get('QUERY_STRING'))	# query string
 		self.callback	= query_data.pop("callback") if "callback" in query_data else None
 		self.query_data	= query_data
+		self.form_vals	= {}
 		self.form_data	= {}
 		self.method		= env.get('REQUEST_METHOD')
 
 		if self.method == 'POST':
-			form_vals		= env['wsgi.input'].read()
-			self.form_data	= parse_qs(form_vals)
+			self.form_vals	= env['wsgi.input'].read()
+			self.form_data	= parse_qs(self.form_vals)
 
 		self._headers	= {}
 		self._cookies	= []
 
 setup(
     name = "gserver",
-    version = "0.1.5",
+    version = "0.1.6",
     author = "Justin Wilson",
     author_email = "justinwilson1@gmail.com",
     description = ("Simple wrapper around gevent's wsgi server."