Remove all usage of six library
Replace six with Python 3 style code. Change-Id: I559fcf1696c2ce62944b501d54695f8d205db0cf
This commit is contained in:
parent
f64c1ea5b3
commit
10cb40e016
|
@ -14,8 +14,11 @@ import collections
|
||||||
from concurrent import futures
|
from concurrent import futures
|
||||||
import copy
|
import copy
|
||||||
from datetime import date
|
from datetime import date
|
||||||
|
import http.client as http_client
|
||||||
|
import io
|
||||||
import json
|
import json
|
||||||
import re
|
import re
|
||||||
|
from urllib.parse import urlencode as compat_urlencode
|
||||||
|
|
||||||
from dateutil import parser
|
from dateutil import parser
|
||||||
from dateutil.relativedelta import relativedelta
|
from dateutil.relativedelta import relativedelta
|
||||||
|
@ -25,9 +28,6 @@ from errbot import BotPlugin
|
||||||
import feedparser
|
import feedparser
|
||||||
from oslo_utils import timeutils
|
from oslo_utils import timeutils
|
||||||
import requests
|
import requests
|
||||||
import six
|
|
||||||
from six.moves import http_client
|
|
||||||
from six.moves.urllib.parse import urlencode as compat_urlencode
|
|
||||||
from tabulate import tabulate
|
from tabulate import tabulate
|
||||||
|
|
||||||
BAD_VALUE = '??'
|
BAD_VALUE = '??'
|
||||||
|
@ -383,7 +383,7 @@ class OsloBotPlugin(BotPlugin):
|
||||||
str(last_fail_url),
|
str(last_fail_url),
|
||||||
str(result.get('discarded', 0)),
|
str(result.get('discarded', 0)),
|
||||||
])
|
])
|
||||||
buf = six.StringIO()
|
buf = io.StringIO()
|
||||||
buf.write(tabulate(tbl_body, tbl_headers,
|
buf.write(tabulate(tbl_body, tbl_headers,
|
||||||
tablefmt=self.config['tabulate_format']))
|
tablefmt=self.config['tabulate_format']))
|
||||||
return buf.getvalue()
|
return buf.getvalue()
|
||||||
|
|
|
@ -1,6 +1,5 @@
|
||||||
errbot
|
errbot
|
||||||
errbot[irc]
|
errbot[irc]
|
||||||
six
|
|
||||||
irc
|
irc
|
||||||
python-dateutil
|
python-dateutil
|
||||||
requests
|
requests
|
||||||
|
|
Loading…
Reference in New Issue