summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorZac Medico <zmedico@gentoo.org>2011-06-03 17:01:13 -0700
committerZac Medico <zmedico@gentoo.org>2011-06-03 17:01:13 -0700
commitf95d917258f4bf9d56f20588b6dab5f5d1e0cc40 (patch)
tree476ba2e2917c0456c248d19a4c7b65e667e148ef
parent7425033c9da717ef2c48e7435bcce248531f9df6 (diff)
downloadportage-f95d917258f4bf9d56f20588b6dab5f5d1e0cc40.tar.gz
portage-f95d917258f4bf9d56f20588b6dab5f5d1e0cc40.tar.bz2
portage-f95d917258f4bf9d56f20588b6dab5f5d1e0cc40.zip
Move pickle import out of base portage module.
-rw-r--r--pym/portage/__init__.py4
-rw-r--r--pym/portage/util/__init__.py2
-rw-r--r--pym/portage/util/mtimedb.py6
3 files changed, 6 insertions, 6 deletions
diff --git a/pym/portage/__init__.py b/pym/portage/__init__.py
index 9732a74b1..1b96dab58 100644
--- a/pym/portage/__init__.py
+++ b/pym/portage/__init__.py
@@ -17,10 +17,6 @@ try:
errno.ESTALE = -1
import re
import types
- try:
- import cPickle as pickle
- except ImportError:
- import pickle
try:
from subprocess import getstatusoutput as subprocess_getstatusoutput
diff --git a/pym/portage/util/__init__.py b/pym/portage/util/__init__.py
index 138553a16..28e9428d9 100644
--- a/pym/portage/util/__init__.py
+++ b/pym/portage/util/__init__.py
@@ -28,12 +28,12 @@ import traceback
import portage
portage.proxy.lazyimport.lazyimport(globals(),
+ 'pickle',
'portage.dep:Atom',
'portage.util.listdir:_ignorecvs_dirs'
)
from portage import StringIO
from portage import os
-from portage import pickle
from portage import subprocess_getstatusoutput
from portage import _encodings
from portage import _os_merge
diff --git a/pym/portage/util/mtimedb.py b/pym/portage/util/mtimedb.py
index 175bd8f46..571fe5a30 100644
--- a/pym/portage/util/mtimedb.py
+++ b/pym/portage/util/mtimedb.py
@@ -4,9 +4,13 @@
__all__ = ['MtimeDB']
import copy
+try:
+ import cPickle as pickle
+except ImportError:
+ import pickle
import portage
-from portage import pickle, _unicode_encode
+from portage import _unicode_encode
from portage.data import portage_gid, uid
from portage.localization import _
from portage.util import apply_secpass_permissions, atomic_ofstream, writemsg