Remove hacking rules for python 2/3 compatibility
The Python 2.7 Support has been dropped since Ussuri.
So remove hacking rules for compatibility between python 2 and 3.
- [N325] str() and unicode() cannot be used on an exception.
Remove or use six.text_type()
- [N327] Do not use xrange(). xrange() is not compatible with Python 3.
Use range() or six.moves.range() instead.
- [N344] Python 3: do not use dict.iteritems.
- [N345] Python 3: do not use dict.iterkeys.
- [N346] Python 3: do not use dict.itervalues.
See also line 414 in https://etherpad.opendev.org/p/nova-victoria-ptg
Change-Id: If4335b2e8ef5bbabba37598110c1aa8269635c2f
Implements: blueprint six-removal
Signed-off-by: Takashi Natsume <takanattie@gmail.com>
This commit is contained in:
@@ -288,7 +288,6 @@ extension =
|
||||
N323 = checks:check_explicit_underscore_import
|
||||
N324 = checks:use_jsonutils
|
||||
N332 = checks:check_api_version_decorator
|
||||
N325 = checks:CheckForStrUnicodeExc
|
||||
N326 = checks:CheckForTransAdd
|
||||
N334 = checks:assert_true_or_false_with_in
|
||||
N336 = checks:dict_constructor_with_list_copy
|
||||
@@ -300,10 +299,6 @@ extension =
|
||||
N350 = checks:check_policy_registration_in_central_place
|
||||
N351 = checks:check_policy_enforce
|
||||
N343 = checks:check_doubled_words
|
||||
N344 = checks:check_python3_no_iteritems
|
||||
N345 = checks:check_python3_no_iterkeys
|
||||
N346 = checks:check_python3_no_itervalues
|
||||
N327 = checks:check_python3_xrange
|
||||
N348 = checks:no_os_popen
|
||||
N352 = checks:no_log_warn
|
||||
N349 = checks:CheckForUncalledTestClosure
|
||||
|
||||
Reference in New Issue
Block a user