remove unicode literal from code
All strings are considered as unicode string from Python 3. This patch drops the explicit unicode literal (u'...') appearances from the unicode strings. Change-Id: I2e833d293130aff983f3124853df0bd2ed553def
This commit is contained in:
parent
93c2c95871
commit
bffaa7d3a4
@ -82,8 +82,8 @@ openstackdocs_auto_name = False
|
||||
openstackdocs_repo_name = 'openstack/freezer'
|
||||
openstackdocs_bug_project = 'freezer'
|
||||
openstackdocs_bug_tag = 'doc'
|
||||
project = u'Freezer'
|
||||
copyright = u'OpenStack Foundation'
|
||||
project = 'Freezer'
|
||||
copyright = 'OpenStack Foundation'
|
||||
|
||||
# The version info for the project you're documenting, acts as replacement for
|
||||
# |version| and |release|, also used in various other places throughout the
|
||||
@ -144,11 +144,11 @@ modindex_common_prefix = ['freezer.']
|
||||
# -- Options for man page output ----------------------------------------------
|
||||
|
||||
# Grouping the document tree for man pages.
|
||||
# List of tuples 'sourcefile', 'target', u'title', u'Authors name', 'manual'
|
||||
# List of tuples 'sourcefile', 'target', 'title', 'Authors name', 'manual'
|
||||
|
||||
man_pages = [
|
||||
('man/freezer-manage', 'freezer-manage', u'Cloud controller fabric',
|
||||
[u'OpenStack'], 1)
|
||||
('man/freezer-manage', 'freezer-manage', 'Cloud controller fabric',
|
||||
['OpenStack'], 1)
|
||||
]
|
||||
|
||||
# -- Options for HTML output --------------------------------------------------
|
||||
|
@ -258,7 +258,7 @@ def lvm_guess(mount_point_path, mount_points, source='/proc/mounts'):
|
||||
if mount_match:
|
||||
lvm_volgroup = mount_match.group(1).replace('--', '-')
|
||||
lvm_srcvol = mount_match.group(2).replace('--', '-')
|
||||
lvm_device = u'/dev/{0}/{1}'.format(lvm_volgroup, lvm_srcvol)
|
||||
lvm_device = '/dev/{0}/{1}'.format(lvm_volgroup, lvm_srcvol)
|
||||
break
|
||||
|
||||
return lvm_volgroup, lvm_srcvol, lvm_device
|
||||
|
@ -115,8 +115,8 @@ class SwiftStorage(physical.PhysicalStorage):
|
||||
LOG.info('[*] Uploading Swift Manifest: {0}'.format(backup))
|
||||
split = backup.data_path.rsplit('/', 1)
|
||||
self.swift().put_object(container=split[0], obj=split[1],
|
||||
contents=u'', headers=headers,
|
||||
content_length=len(u''))
|
||||
contents='', headers=headers,
|
||||
content_length=len(''))
|
||||
LOG.info('Manifest successfully uploaded!')
|
||||
|
||||
def prepare(self):
|
||||
@ -175,8 +175,8 @@ class SwiftStorage(physical.PhysicalStorage):
|
||||
objname = package_name.rsplit('/', 1)[1]
|
||||
# This call sets the metadata on a file which will be used to download
|
||||
# the whole backup later. Do not remove it ! (szaher)
|
||||
self.swift().put_object(container=full_path, obj=objname, contents=u'',
|
||||
content_length=len(u''), headers=headers)
|
||||
self.swift().put_object(container=full_path, obj=objname, contents='',
|
||||
content_length=len(''), headers=headers)
|
||||
|
||||
def backup_blocks(self, backup):
|
||||
"""
|
||||
@ -207,7 +207,7 @@ class SwiftStorage(physical.PhysicalStorage):
|
||||
"""
|
||||
backup = backup.copy(storage=self)
|
||||
for block_index, message in enumerate(rich_queue.get_messages()):
|
||||
segment_package_name = u'{0}/{1}'.format(
|
||||
segment_package_name = '{0}/{1}'.format(
|
||||
backup.segments_path, "%08d" % block_index)
|
||||
self.upload_chunk(message, segment_package_name)
|
||||
self.upload_manifest(backup)
|
||||
|
@ -543,9 +543,9 @@ def set_max_process_priority():
|
||||
os.nice(-19)
|
||||
# Set I/O Priority to Real Time class with level 0
|
||||
subprocess.call([
|
||||
u'{0}'.format(find_executable("ionice")),
|
||||
u'-c', u'1', u'-n', u'0', u'-t',
|
||||
u'-p', u'{0}'.format(pid)
|
||||
'{0}'.format(find_executable("ionice")),
|
||||
'-c', '1', '-n', '0', '-t',
|
||||
'-p', '{0}'.format(pid)
|
||||
])
|
||||
except Exception as priority_error:
|
||||
LOG.warning('Priority: {0}'.format(priority_error))
|
||||
|
@ -58,7 +58,7 @@ source_suffix = '.rst'
|
||||
master_doc = 'index'
|
||||
|
||||
# General information about the project.
|
||||
copyright = u'2016, Freezer developers'
|
||||
copyright = '2016, Freezer developers'
|
||||
|
||||
# Release notes are version independent.
|
||||
# The short X.Y version.
|
||||
@ -194,8 +194,8 @@ htmlhelp_basename = 'FreezerReleaseNotestdoc'
|
||||
# (source start file, target name, title,
|
||||
# author, documentclass [howto, manual, or own class]).
|
||||
latex_documents = [
|
||||
('index', 'PythonFreezer.tex', u'Freezer Release Notes Documentation',
|
||||
u'Freezer developers', 'manual'),
|
||||
('index', 'PythonFreezer.tex', 'Freezer Release Notes Documentation',
|
||||
'Freezer developers', 'manual'),
|
||||
]
|
||||
|
||||
# The name of an image file (relative to this directory) to place at the top of
|
||||
@ -225,8 +225,8 @@ latex_documents = [
|
||||
# (source start file, name, description, authors, manual section).
|
||||
man_pages = [
|
||||
('index', 'freezer',
|
||||
u'Freezer Release Notes Documentation',
|
||||
[u'Freezer developers'], 1)
|
||||
'Freezer Release Notes Documentation',
|
||||
['Freezer developers'], 1)
|
||||
]
|
||||
|
||||
# If true, show URL addresses after external links.
|
||||
@ -240,8 +240,8 @@ man_pages = [
|
||||
# dir menu entry, description, category)
|
||||
texinfo_documents = [
|
||||
('index', 'Freezer',
|
||||
u'Freezer Release Notes Documentation',
|
||||
u'Freezer developers', 'Freezer',
|
||||
'Freezer Release Notes Documentation',
|
||||
'Freezer developers', 'Freezer',
|
||||
'One line description of project.', 'Miscellaneous'),
|
||||
]
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user