root/trunk/twisted/internet/qtreactor.py

Revision 27869, 0.6 KB (checked in by jesstess, 8 months ago)

Merge qtreactor-qtstub-2608

Author: jesstess
Reviewers: exarkun, washort, TimAllen, therve,
Fixes: #2608

twisted.internet.qtreactor no longer tries to import the non-existent
qtreactor_stub and instead imports twisted_qtstub.

Line 
1# -*- test-case-name: twisted.internet.test.test_qtreactor -*-
2# Copyright (c) 2001-2009 Twisted Matrix Laboratories.
3# See LICENSE for details.
4
5try:
6    # 'import qtreactor' would have imported this file instead of the
7    # top-level qtreactor. __import__ does the right thing
8    # (kids, don't repeat this at home)
9    install = __import__('qtreactor').install
10except ImportError:
11    from twisted.plugins.twisted_qtstub import errorMessage
12    raise ImportError(errorMessage)
13else:
14    import warnings
15    warnings.warn("Please use qtreactor instead of twisted.internet.qtreactor",
16                  category=DeprecationWarning)
17
18__all__ = ['install']
Note: See TracBrowser for help on using the browser.