Use six.moves cStringIO instead of cStringIO
to keep Python 3.x compatibility, use six.moves.cStringIO to replace StringIO Change-Id: Id89c6156d9bba0007e8b16cd2cc28413a7cc5fd3 Closes-Bug: #1280964
This commit is contained in:
parent
37eb101b1c
commit
6427b5506d
@ -18,13 +18,13 @@
|
||||
|
||||
from __future__ import print_function
|
||||
|
||||
import cStringIO as StringIO
|
||||
import json
|
||||
import re
|
||||
import sys
|
||||
|
||||
from pylint import lint
|
||||
from pylint.reporters import text
|
||||
from six.moves import cStringIO as StringIO
|
||||
|
||||
# Note(maoy): E1103 is error code related to partial type inference
|
||||
ignore_codes = ["E1103"]
|
||||
@ -127,7 +127,7 @@ class ErrorKeys(object):
|
||||
|
||||
|
||||
def run_pylint():
|
||||
buff = StringIO.StringIO()
|
||||
buff = StringIO()
|
||||
reporter = text.ParseableTextReporter(output=buff)
|
||||
args = ["--include-ids=y", "-E", "cinder"]
|
||||
lint.Run(args, reporter=reporter, exit=False)
|
||||
|
Loading…
x
Reference in New Issue
Block a user