summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLucas Hoffmann <l-m-h@web.de>2017-01-14 11:46:11 +0100
committerLucas Hoffmann <l-m-h@web.de>2017-01-18 11:39:06 +0100
commit1808e4963e7da1b18319fdca44866dc2a71c62a0 (patch)
tree747217b535ee66fb90f5d4931fb0e8f64914d120
parent70cae61d4fa80e2090169f8cb83e69081a04f890 (diff)
Use absolute_imports from __future__
-rw-r--r--alot/__main__.py2
-rw-r--r--alot/account.py2
-rw-r--r--alot/addressbook/__init__.py2
-rw-r--r--alot/addressbook/abook.py1
-rw-r--r--alot/addressbook/external.py2
-rw-r--r--alot/buffers.py2
-rw-r--r--alot/commands/__init__.py2
-rw-r--r--alot/commands/bufferlist.py2
-rw-r--r--alot/commands/envelope.py2
-rw-r--r--alot/commands/globals.py2
-rw-r--r--alot/commands/search.py2
-rw-r--r--alot/commands/taglist.py2
-rw-r--r--alot/commands/thread.py2
-rw-r--r--alot/commands/utils.py2
-rw-r--r--alot/completion.py2
-rw-r--r--alot/crypto.py2
-rw-r--r--alot/db/__init__.py2
-rw-r--r--alot/db/attachment.py2
-rw-r--r--alot/db/envelope.py2
-rw-r--r--alot/db/manager.py2
-rw-r--r--alot/db/message.py2
-rw-r--r--alot/db/thread.py2
-rw-r--r--alot/db/utils.py2
-rw-r--r--alot/helper.py2
-rw-r--r--alot/settings/__init__.py2
-rw-r--r--alot/settings/checks.py2
-rw-r--r--alot/settings/manager.py2
-rw-r--r--alot/settings/theme.py2
-rw-r--r--alot/settings/utils.py2
-rw-r--r--alot/ui.py2
-rw-r--r--alot/utils/booleanaction.py2
-rw-r--r--alot/walker.py2
-rw-r--r--alot/widgets/bufferlist.py2
-rw-r--r--alot/widgets/globals.py2
-rw-r--r--alot/widgets/search.py2
-rw-r--r--alot/widgets/thread.py2
-rw-r--r--alot/widgets/utils.py2
-rw-r--r--docs/source/api/conf.py1
-rw-r--r--docs/source/conf.py1
-rwxr-xr-xdocs/source/generate_commands.py1
-rwxr-xr-xdocs/source/generate_configs.py1
-rwxr-xr-xextra/colour_picker.py1
-rw-r--r--tests/commands/init_test.py2
-rw-r--r--tests/db/envelop_test.py1
-rw-r--r--tests/db/thread_test.py1
-rw-r--r--tests/helper_test.py1
-rw-r--r--tests/settings/checks_test.py1
47 files changed, 84 insertions, 0 deletions
diff --git a/alot/__main__.py b/alot/__main__.py
index d68b5b87..8694311d 100644
--- a/alot/__main__.py
+++ b/alot/__main__.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import argparse
import logging
import os
diff --git a/alot/account.py b/alot/account.py
index 5e66e9bf..7d57a94c 100644
--- a/alot/account.py
+++ b/alot/account.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import abc
import glob
import logging
diff --git a/alot/addressbook/__init__.py b/alot/addressbook/__init__.py
index da0863f4..cda2d8bd 100644
--- a/alot/addressbook/__init__.py
+++ b/alot/addressbook/__init__.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2015 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import re
import abc
diff --git a/alot/addressbook/abook.py b/alot/addressbook/abook.py
index 207d8153..b620fbac 100644
--- a/alot/addressbook/abook.py
+++ b/alot/addressbook/abook.py
@@ -1,6 +1,7 @@
# Copyright (C) 2011-2015 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
import os
from . import AddressBook
diff --git a/alot/addressbook/external.py b/alot/addressbook/external.py
index 5c88b291..6a89dd15 100644
--- a/alot/addressbook/external.py
+++ b/alot/addressbook/external.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2015 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import re
from ..helper import call_cmd
diff --git a/alot/buffers.py b/alot/buffers.py
index 8dcb7352..e2640d5d 100644
--- a/alot/buffers.py
+++ b/alot/buffers.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import logging
import os
diff --git a/alot/commands/__init__.py b/alot/commands/__init__.py
index 47315fc3..5df88747 100644
--- a/alot/commands/__init__.py
+++ b/alot/commands/__init__.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import argparse
import glob
import logging
diff --git a/alot/commands/bufferlist.py b/alot/commands/bufferlist.py
index 73bd12a4..1a9bbdeb 100644
--- a/alot/commands/bufferlist.py
+++ b/alot/commands/bufferlist.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
from ..commands import Command, registerCommand
from . import globals
diff --git a/alot/commands/envelope.py b/alot/commands/envelope.py
index d293a616..5082cc8f 100644
--- a/alot/commands/envelope.py
+++ b/alot/commands/envelope.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import argparse
import datetime
import email
diff --git a/alot/commands/globals.py b/alot/commands/globals.py
index 396bc06b..f74a1662 100644
--- a/alot/commands/globals.py
+++ b/alot/commands/globals.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import argparse
import code
import email
diff --git a/alot/commands/search.py b/alot/commands/search.py
index 5fb8324a..f304973d 100644
--- a/alot/commands/search.py
+++ b/alot/commands/search.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import argparse
import logging
diff --git a/alot/commands/taglist.py b/alot/commands/taglist.py
index 1fa01369..5f90519f 100644
--- a/alot/commands/taglist.py
+++ b/alot/commands/taglist.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
from . import Command, registerCommand
from .globals import SearchCommand
diff --git a/alot/commands/thread.py b/alot/commands/thread.py
index 34256c05..e4334637 100644
--- a/alot/commands/thread.py
+++ b/alot/commands/thread.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import argparse
import logging
import mailcap
diff --git a/alot/commands/utils.py b/alot/commands/utils.py
index 3239f865..2d285f07 100644
--- a/alot/commands/utils.py
+++ b/alot/commands/utils.py
@@ -1,6 +1,8 @@
# Copyright (C) 2015 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import re
import logging
from twisted.internet.defer import inlineCallbacks, returnValue
diff --git a/alot/completion.py b/alot/completion.py
index 41d04b8d..082cae12 100644
--- a/alot/completion.py
+++ b/alot/completion.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import abc
import argparse
import glob
diff --git a/alot/crypto.py b/alot/crypto.py
index dc9a0077..30de529f 100644
--- a/alot/crypto.py
+++ b/alot/crypto.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import os
from cStringIO import StringIO
import gpgme
diff --git a/alot/db/__init__.py b/alot/db/__init__.py
index e3aded24..37da86e6 100644
--- a/alot/db/__init__.py
+++ b/alot/db/__init__.py
@@ -2,6 +2,8 @@
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
from .thread import Thread
from .message import Message
DB_ENC = 'UTF-8'
diff --git a/alot/db/attachment.py b/alot/db/attachment.py
index a1b7bc04..b35092e5 100644
--- a/alot/db/attachment.py
+++ b/alot/db/attachment.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import os
import tempfile
import email.charset as charset
diff --git a/alot/db/envelope.py b/alot/db/envelope.py
index a2463e9c..2a67a79c 100644
--- a/alot/db/envelope.py
+++ b/alot/db/envelope.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import glob
import logging
import os
diff --git a/alot/db/manager.py b/alot/db/manager.py
index 7f2cf7eb..6bbaca2f 100644
--- a/alot/db/manager.py
+++ b/alot/db/manager.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
from collections import deque
import errno
import logging
diff --git a/alot/db/message.py b/alot/db/message.py
index 049a3521..b553bce2 100644
--- a/alot/db/message.py
+++ b/alot/db/message.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import email
import email.charset as charset
import functools
diff --git a/alot/db/thread.py b/alot/db/thread.py
index ca244d5f..619558b6 100644
--- a/alot/db/thread.py
+++ b/alot/db/thread.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
from datetime import datetime
from .message import Message
diff --git a/alot/db/utils.py b/alot/db/utils.py
index acffe019..cdbd1a4a 100644
--- a/alot/db/utils.py
+++ b/alot/db/utils.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import os
import email
import email.charset as charset
diff --git a/alot/helper.py b/alot/helper.py
index b33c0125..5e957bea 100644
--- a/alot/helper.py
+++ b/alot/helper.py
@@ -2,6 +2,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
from datetime import timedelta
from datetime import datetime
from collections import deque
diff --git a/alot/settings/__init__.py b/alot/settings/__init__.py
index b1449c29..11137d1d 100644
--- a/alot/settings/__init__.py
+++ b/alot/settings/__init__.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
from .manager import SettingsManager
settings = SettingsManager()
diff --git a/alot/settings/checks.py b/alot/settings/checks.py
index 6f909524..125d1860 100644
--- a/alot/settings/checks.py
+++ b/alot/settings/checks.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import mailbox
import re
from urwid import AttrSpec, AttrSpecError
diff --git a/alot/settings/manager.py b/alot/settings/manager.py
index 40a36c66..5e9727f8 100644
--- a/alot/settings/manager.py
+++ b/alot/settings/manager.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import imp
import os
import re
diff --git a/alot/settings/theme.py b/alot/settings/theme.py
index 7c4dac15..c05a4db0 100644
--- a/alot/settings/theme.py
+++ b/alot/settings/theme.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import os
from .utils import read_config
diff --git a/alot/settings/utils.py b/alot/settings/utils.py
index 3b9f1ecc..3cdb51ad 100644
--- a/alot/settings/utils.py
+++ b/alot/settings/utils.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
from configobj import ConfigObj, ConfigObjError, flatten_errors
from validate import Validator
from urwid import AttrSpec
diff --git a/alot/ui.py b/alot/ui.py
index 9d9e365a..7ac4ccc3 100644
--- a/alot/ui.py
+++ b/alot/ui.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import logging
import os
import signal
diff --git a/alot/utils/booleanaction.py b/alot/utils/booleanaction.py
index 82fcedd2..4c9ce1ed 100644
--- a/alot/utils/booleanaction.py
+++ b/alot/utils/booleanaction.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import argparse
diff --git a/alot/walker.py b/alot/walker.py
index feba99b6..11296473 100644
--- a/alot/walker.py
+++ b/alot/walker.py
@@ -1,6 +1,8 @@
# Copyright (C) 2011-2012 Patrick Totzke <patricktotzke@gmail.com>
# This file is released under the GNU GPL, version 3 or a later revision.
# For further details see the COPYING file
+from __future__ import absolute_import
+
import logging
import urwid
diff --git a/alot/widgets/bufferlist.py b/alot/widgets/bufferlist.py
index 0ab315c5..4f9187be 100644
--- a/alot/widgets/bufferlist.py
+++ b/alot/widgets/bufferlist.py
@@ -5,6 +5,8 @@
"""
Widgets specific to Bufferlist mode
"""
+from __future__ import absolute_import
+
import urwid
diff --git a/alot/widgets/globals.py b/alot/widgets/globals.py
index b4fae0c8..388ae76c 100644
--- a/alot/widgets/globals.py
+++ b/alot/widgets/globals.py
@@ -5,6 +5,8 @@
"""
This contains alot-specific :class:`urwid.Widget` used in more than one mode.
"""
+from __future__ import absolute_import
+
import re
import operator
import urwid
diff --git a/alot/widgets/search.py b/alot/widgets/search.py
index d960e919..a0f23b5e 100644
--- a/alot/widgets/search.py
+++ b/alot/widgets/search.py
@@ -4,6 +4,8 @@
"""
Widgets specific to search mode
"""
+from __future__ import absolute_import
+
import urwid
from ..settings import settings
diff --git a/alot/widgets/thread.py b/alot/widgets/thread.py
index 9b8d029d..10e5d59f 100644
--- a/alot/widgets/thread.py
+++ b/alot/widgets/thread.py
@@ -4,6 +4,8 @@
"""
Widgets specific to thread mode
"""
+from __future__ import absolute_import
+
import logging
import urwid
from urwidtrees import Tree, SimpleTree, CollapsibleTree
diff --git a/alot/widgets/utils.py b/alot/widgets/utils.py
index 15a2c60b..86eb49b7 100644
--- a/alot/widgets/utils.py
+++ b/alot/widgets/utils.py
@@ -5,6 +5,8 @@
"""
Utility Widgets not specific to alot
"""
+from __future__ import absolute_import
+
import urwid
diff --git a/docs/source/api/conf.py b/docs/source/api/conf.py
index 348a8b6e..101fce21 100644
--- a/docs/source/api/conf.py
+++ b/docs/source/api/conf.py
@@ -10,6 +10,7 @@
#
# All configuration values have a default; values that are commented out
# serve to show the default.
+from __future__ import absolute_import
import sys, os
diff --git a/docs/source/conf.py b/docs/source/conf.py
index 3f1e17ae..5ebab550 100644
--- a/docs/source/conf.py
+++ b/docs/source/conf.py
@@ -1,5 +1,6 @@
# -*- coding: utf-8 -*-
# alot documentation build configuration file
+from __future__ import absolute_import
import sys, os
diff --git a/docs/source/generate_commands.py b/docs/source/generate_commands.py
index 0fd1fb01..19719544 100755
--- a/docs/source/generate_commands.py
+++ b/docs/source/generate_commands.py
@@ -1,3 +1,4 @@
+from __future__ import absolute_import
import sys
import os
HERE = os.path.dirname(__file__)
diff --git a/docs/source/generate_configs.py b/docs/source/generate_configs.py
index b79f3f69..2b9cc806 100755
--- a/docs/source/generate_configs.py
+++ b/docs/source/generate_configs.py
@@ -1,3 +1,4 @@
+from __future__ import absolute_import
import sys
import os
HERE = os.path.dirname(__file__)
diff --git a/extra/colour_picker.py b/extra/colour_picker.py
index badb494e..8c28a2ee 100755
--- a/extra/colour_picker.py
+++ b/extra/colour_picker.py
@@ -31,6 +31,7 @@
Palette test. Shows the available foreground and background settings
in monochrome, 16 color, 88 color and 256 color modes.
"""
+from __future__ import absolute_import
import re
import sys
diff --git a/tests/commands/init_test.py b/tests/commands/init_test.py
index 189ffc8e..f5a37997 100644
--- a/tests/commands/init_test.py
+++ b/tests/commands/init_test.py
@@ -2,6 +2,8 @@
"""Test suite for alot.commands.__init__ module."""
+from __future__ import absolute_import
+
import argparse
import unittest
diff --git a/tests/db/envelop_test.py b/tests/db/envelop_test.py
index 1895d827..14f5fa1f 100644
--- a/tests/db/envelop_test.py
+++ b/tests/db/envelop_test.py
@@ -1,4 +1,5 @@
# encoding=utf-8
+from __future__ import absolute_import
import unittest
diff --git a/tests/db/thread_test.py b/tests/db/thread_test.py
index 7f802e15..678a5e59 100644
--- a/tests/db/thread_test.py
+++ b/tests/db/thread_test.py
@@ -15,6 +15,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
"""Tests for the alot.db.thread module."""
+from __future__ import absolute_import
import datetime
import unittest
diff --git a/tests/helper_test.py b/tests/helper_test.py
index e333c2f9..5a5c60da 100644
--- a/tests/helper_test.py
+++ b/tests/helper_test.py
@@ -1,6 +1,7 @@
# encoding=utf-8
"""Test suite for alot.helper module."""
+from __future__ import absolute_import
import unittest
diff --git a/tests/settings/checks_test.py b/tests/settings/checks_test.py
index 917e2438..86269c29 100644
--- a/tests/settings/checks_test.py
+++ b/tests/settings/checks_test.py
@@ -1,4 +1,5 @@
# encoding=utf-8
+from __future__ import absolute_import
import unittest