def exec_watch(cmd, **options):
"""Run program with stdout shown on sys.stdout"""
- if isinstance(cmd, basestring) and not "shell" in options:
+ if isinstance(cmd, str) and not "shell" in options:
options["shell"] = True
process = subprocess.Popen(
def exec_watch(cmd, **options):
"""Run program with stdout shown on sys.stdout"""
import bb
- if isinstance(cmd, basestring) and not "shell" in options:
+ if isinstance(cmd, str) and not "shell" in options:
options["shell"] = True
process = subprocess.Popen(
unmappedpc = []
pcdeps = list(set(pcdeps))
for pcdep in pcdeps:
- if isinstance(pcdep, basestring):
+ if isinstance(pcdep, str):
recipe = recipemap.get(pcdep, None)
if recipe:
deps.append(recipe)
if field not in self.bbvar_map:
continue
- if isinstance(values, basestring):
+ if isinstance(values, str):
value = values
else:
value = ' '.join(str(v) for v in values if v)
return value
value = info[variable]
- if isinstance(value, basestring):
+ if isinstance(value, str):
new_value = replace_value(search, replace, value)
if new_value is None:
del info[variable]
def has_non_literals(value):
if isinstance(value, ast.AST):
return True
- elif isinstance(value, basestring):
+ elif isinstance(value, str):
return False
elif hasattr(value, 'values'):
return any(has_non_literals(v) for v in value.values())
return ret
def run_editor(fn):
- if isinstance(fn, basestring):
+ if isinstance(fn, str):
params = '"%s"' % fn
else:
params = ''