Index: server/lib/gutenbach/server/__init__.py
===================================================================
--- server/lib/gutenbach/server/__init__.py	(revision 7bd1035512a62917148a585e099d7632eee2a5c8)
+++ server/lib/gutenbach/server/__init__.py	(revision 6effd500f1a343da7fc04b1dff40e47d90db5b3a)
@@ -2,11 +2,16 @@
 import BaseHTTPServer
 import logging
+import sys
 
 # configure logging
-logging.basicConfig(level=logging.INFO)
+logging.basicConfig(level=logging.DEBUG)
+
+def error(self, request, client_address):
+    sys.exit(1)
 
 def start():
     server_address = ('', 8000)
     httpd = BaseHTTPServer.HTTPServer(server_address, GutenbachIPPServer)
+    httpd.handle_error = error.__get__(httpd)
     httpd.serve_forever()
 
Index: server/lib/gutenbach/server/printer.py
===================================================================
--- server/lib/gutenbach/server/printer.py	(revision 5fe360ebb182134a3c0a7bc5197c691a7dafe68d)
+++ server/lib/gutenbach/server/printer.py	(revision 6effd500f1a343da7fc04b1dff40e47d90db5b3a)
@@ -61,17 +61,15 @@
     def __getattr__(self, attr):
         try:
-            return super(Printer, self).__getattr__(attr)
+            return self.__getattribute__(attr)
         except AttributeError:
             pass
-
-        return super(Printer, self).__getattr__(
-            attr.replace("-", "_"))
+        return self.__getattribute__(attr.replace("-", "_"))
 
     def __hasattr__(self, attr):
-        has = super(Printer, self).__hasattr__(attr)
-        if not has:
-            has = super(Printer, self).__hasattr__(
-                attr.replace("-", "_"))
-        return has
+        try:
+            getattr(self, attr)
+            return True
+        except AttributeError:
+            return False
 
     ## Printer attributes
@@ -156,5 +154,6 @@
     def get_printer_attributes(self, request):
         attributes = [(attr, getattr(self, attr)) for attr in self.attributes]
-        attributes = map(lambda x: x if isinstance(x, (tuple, list)) else [x], attributes)
+        attributes = map(lambda x: x if isinstance(x[1], (tuple, list)) else (x[0], [x[1]]),
+                         attributes)
         return attributes
 
Index: server/lib/gutenbach/server/requests.py
===================================================================
--- server/lib/gutenbach/server/requests.py	(revision 5fe360ebb182134a3c0a7bc5197c691a7dafe68d)
+++ server/lib/gutenbach/server/requests.py	(revision 6effd500f1a343da7fc04b1dff40e47d90db5b3a)
@@ -53,5 +53,5 @@
         attrs = printer.get_printer_attributes(request)
         ipp_attrs = []
-        for attr, vals in enumerate(attrs):
+        for attr, vals in attrs:
             ipp_vals = [ipp.Value(
                 tag=printer_attribute_value_tags[attr],
@@ -64,5 +64,5 @@
         attrs = job.get_job_attributes(request)
         ipp_attrs = []
-        for attr, vals in enumerate(attrs):
+        for attr, vals in attrs:
             ipp_vals = [ipp.Value(
                 tag=job_attribute_value_tags[attr],
Index: server/lib/gutenbach/server/server.py
===================================================================
--- server/lib/gutenbach/server/server.py	(revision dc40fe92358ddb658b3d7adb7fb2dd6d9e3261cd)
+++ server/lib/gutenbach/server/server.py	(revision 6effd500f1a343da7fc04b1dff40e47d90db5b3a)
@@ -41,5 +41,5 @@
         # is an IPP error, then we can get the error code from the
         # exception itself.
-        except IPPException:
+        except ipp.errors.IPPException:
             exctype, excval, exctb = sys.exc_info()
             excval.update_response(response)
@@ -49,12 +49,18 @@
         # as an internal server error
         except Exception:
-            response.operation_id = const.ErrorCodes.INTERNAL_ERROR
+            response.operation_id = ipp.StatusCodes.INTERNAL_ERROR
             logger.error(traceback.format_exc())
 
         # Send the response across HTTP
         logger.debug("Sending response: %s" % repr(response))
+        try:
+            binary = response.packed_value
+        except:
+            logger.fatal(traceback.format_exc())
+            sys.exit(1)
+            
         self.send_response(200, "Gutenbach IPP Response")
         self.send_header("Content-Type", "application/ipp")
         self.send_header("Connection", "close")
         self.end_headers()
-        self.wfile.write(response.packed_value)
+        self.wfile.write(binary)
