first step in python3 support
This commit is contained in:
parent
7c1e08eb96
commit
6fcac89dd5
25 changed files with 302 additions and 208 deletions
|
|
@ -17,10 +17,13 @@
|
|||
# You should have received a copy of the GNU Affero General Public License
|
||||
# along with weboob. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
from __future__ import absolute_import
|
||||
from __future__ import absolute_import, print_function
|
||||
|
||||
import re
|
||||
from urlparse import urlparse, urljoin
|
||||
try:
|
||||
from urllib.parse import urlparse, urljoin
|
||||
except ImportError:
|
||||
from urlparse import urlparse, urljoin
|
||||
import mimetypes
|
||||
import os
|
||||
import tempfile
|
||||
|
|
@ -157,7 +160,7 @@ class BaseBrowser(object):
|
|||
def _save(self, response, warning=False, **kwargs):
|
||||
if self.responses_dirname is None:
|
||||
self.responses_dirname = tempfile.mkdtemp(prefix='weboob_session_')
|
||||
print >>sys.stderr, 'Debug data will be saved in this directory: %s' % self.responses_dirname
|
||||
print('Debug data will be saved in this directory: %s' % self.responses_dirname, file=sys.stderr)
|
||||
elif not os.path.isdir(self.responses_dirname):
|
||||
os.makedirs(self.responses_dirname)
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue