File: twisted.py

package info (click to toggle)
python-application 1.3.0-1
  • links: PTS, VCS
  • area: main
  • in suites: wheezy
  • size: 288 kB
  • sloc: python: 1,878; makefile: 2
file content (17 lines) | stat: -rw-r--r-- 423 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# Copyright (C) 2009 Dan Pascu. See LICENSE for details.
#

from __future__ import absolute_import
from application.log.extensions import twisted as fake_twisted
import sys, os

try:
    sys.path.remove(os.path.realpath(fake_twisted.__path__[0]))
except ValueError:
    pass
else:
    sys.modules.pop('twisted', None)
    import twisted
    from application.log.extensions.twisted import divert_logger
    divert_logger()