Browse Source

Fix wrapping.

pull/24/head
Ben Kurtovic 10 years ago
parent
commit
246c987f72
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      app.fcgi

+ 3
- 1
app.fcgi View File

@@ -1,9 +1,10 @@
#! /data/project/copyvios/env/bin/python #! /data/project/copyvios/env/bin/python
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-


from time import asctime
from functools import wraps
from logging import DEBUG from logging import DEBUG
from logging.handlers import TimedRotatingFileHandler from logging.handlers import TimedRotatingFileHandler
from time import asctime


from flask import Flask, g, request from flask import Flask, g, request
from flask.ext.mako import MakoTemplates, render_template, TemplateError from flask.ext.mako import MakoTemplates, render_template, TemplateError
@@ -20,6 +21,7 @@ app.logger.addHandler(TimedRotatingFileHandler(
app.logger.info(u"Flask server started " + asctime()) app.logger.info(u"Flask server started " + asctime())


def debug_exceptions(func): def debug_exceptions(func):
@wraps(func)
def inner(*args, **kwargs): def inner(*args, **kwargs):
try: try:
return func(*args, **kwargs) return func(*args, **kwargs)


Loading…
Cancel
Save