From ca0950db07ff5006ba760e829f2fa6a7c2f8ea41 Mon Sep 17 00:00:00 2001 From: mathieui Date: Fri, 4 Apr 2014 00:24:16 +0200 Subject: Remove unused imports (thanks eijebong) --- src/bookmark.py | 1 - src/config.py | 7 ++----- src/connection.py | 4 ---- src/contact.py | 1 - src/core.py | 4 ++-- src/data_forms.py | 1 - src/logger.py | 2 +- src/plugin_manager.py | 1 - src/poezio.py | 1 - src/pubsub.py | 2 +- src/tabs/basetabs.py | 2 +- src/tabs/muctab.py | 2 +- src/tabs/privatetab.py | 1 - src/windows.py | 5 +---- 14 files changed, 9 insertions(+), 25 deletions(-) (limited to 'src') diff --git a/src/bookmark.py b/src/bookmark.py index 98bfecc4..52235d23 100644 --- a/src/bookmark.py +++ b/src/bookmark.py @@ -8,7 +8,6 @@ bookmark storage. It can also parse xml Elements. This module also defines several functions for retrieving and updating bookmarks, both local and remote. """ -import os import logging from sys import version_info diff --git a/src/config.py b/src/config.py index 6b0acf2c..2ac85c45 100644 --- a/src/config.py +++ b/src/config.py @@ -12,12 +12,9 @@ from/to the config file DEFSECTION = "Poezio" -from gettext import gettext as _ -import sys -import tempfile - -import os import logging +import os +import sys from configparser import RawConfigParser, NoOptionError, NoSectionError from os import environ, makedirs, path, remove diff --git a/src/connection.py b/src/connection.py index 3010a9fe..f9e6ddfa 100644 --- a/src/connection.py +++ b/src/connection.py @@ -12,15 +12,11 @@ Defines the Connection class import logging log = logging.getLogger(__name__) -from gettext import (bindtextdomain, textdomain, bind_textdomain_codeset, - gettext as _) import getpass -import sys import sleekxmpp from config import config, options -from logger import logger import common from common import safeJID diff --git a/src/contact.py b/src/contact.py index 93f2f69e..4cb4c789 100644 --- a/src/contact.py +++ b/src/contact.py @@ -13,7 +13,6 @@ the roster. import logging log = logging.getLogger(__name__) -from sleekxmpp import JID from common import safeJID from collections import defaultdict diff --git a/src/core.py b/src/core.py index b7f6ea17..2e78005b 100644 --- a/src/core.py +++ b/src/core.py @@ -7,10 +7,10 @@ from gettext import gettext as _ +import curses import os import sys import time -import curses import pipes import ssl @@ -27,7 +27,7 @@ import logging import singleton import collections -from sleekxmpp import JID, InvalidJID +from sleekxmpp import InvalidJID from common import safeJID from sleekxmpp.xmlstream.stanzabase import StanzaBase from sleekxmpp.xmlstream.handler import Callback diff --git a/src/data_forms.py b/src/data_forms.py index 89781377..8de05bbd 100644 --- a/src/data_forms.py +++ b/src/data_forms.py @@ -11,7 +11,6 @@ Defines the data-forms Tab and all the Windows for it. import logging log = logging.getLogger(__name__) -import curses from windows import g_lock import windows diff --git a/src/logger.py b/src/logger.py index 2c878606..6248cfdf 100644 --- a/src/logger.py +++ b/src/logger.py @@ -8,7 +8,7 @@ import mmap import os import re -from os import environ, makedirs +from os import makedirs from datetime import datetime import common diff --git a/src/plugin_manager.py b/src/plugin_manager.py index d691b3b5..45fccb10 100644 --- a/src/plugin_manager.py +++ b/src/plugin_manager.py @@ -8,7 +8,6 @@ plugin env. import imp import os from os import path -import sys import logging from gettext import gettext as _ from sys import version_info diff --git a/src/poezio.py b/src/poezio.py index 3245be09..7218cf13 100644 --- a/src/poezio.py +++ b/src/poezio.py @@ -19,7 +19,6 @@ import logging.config sys.path.append(os.path.dirname(os.path.abspath(__file__))) from config import options -from logger import logger import singleton import core diff --git a/src/pubsub.py b/src/pubsub.py index 6ef23323..55e9bc38 100644 --- a/src/pubsub.py +++ b/src/pubsub.py @@ -20,7 +20,7 @@ import atom_parser from config import config from datetime import datetime -from sleekxmpp.xmlstream import ElementBase, ET +from sleekxmpp.xmlstream import ET ATOM_XMLNS = "http://www.w3.org/2005/Atom" diff --git a/src/tabs/basetabs.py b/src/tabs/basetabs.py index c58efc26..d4704b79 100644 --- a/src/tabs/basetabs.py +++ b/src/tabs/basetabs.py @@ -33,7 +33,7 @@ from common import safeJID from config import config from decorators import refresh_wrapper from logger import logger -from text_buffer import TextBuffer, CorrectionError +from text_buffer import TextBuffer from theming import get_theme diff --git a/src/tabs/muctab.py b/src/tabs/muctab.py index 5a271736..bb094bbf 100644 --- a/src/tabs/muctab.py +++ b/src/tabs/muctab.py @@ -15,7 +15,7 @@ log = logging.getLogger(__name__) import curses import os import random -from datetime import datetime, timedelta +from datetime import datetime from . import ChatTab, Tab diff --git a/src/tabs/privatetab.py b/src/tabs/privatetab.py index 5b9d1cee..7b050769 100644 --- a/src/tabs/privatetab.py +++ b/src/tabs/privatetab.py @@ -19,7 +19,6 @@ import curses from . import ChatTab, MucTab, Tab -import common import fixes import windows import xhtml diff --git a/src/windows.py b/src/windows.py index fd66d475..60871821 100644 --- a/src/windows.py +++ b/src/windows.py @@ -12,8 +12,6 @@ the text window, the roster window, etc. A Tab (see tab.py) is composed of multiple Windows """ -from gettext import (bindtextdomain, textdomain, bind_textdomain_codeset, - gettext as _) import logging log = logging.getLogger(__name__) @@ -30,7 +28,6 @@ from contact import Contact, Resource from roster import RosterGroup import poopt -from sleekxmpp import JID from common import safeJID import common @@ -38,7 +35,7 @@ import core import singleton import collections -from theming import get_theme, to_curses_attr, read_tuple, dump_tuple +from theming import get_theme, to_curses_attr, read_tuple FORMAT_CHAR = '\x19' # These are non-printable chars, so they should never appear in the input, I -- cgit v1.2.3