Make Python path warning say what it means to say (#69669)

pull/69767/head
Karl Fogel 5 years ago committed by GitHub
parent c3dff34c15
commit 225ae65b0f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -156,7 +156,7 @@ def discover_interpreter(action, interpreter_name, discovery_mode, task_vars):
if not is_silent: if not is_silent:
action._discovery_warnings \ action._discovery_warnings \
.append(u"Platform {0} on host {1} is using the discovered Python interpreter at {2}, but future installation of " .append(u"Platform {0} on host {1} is using the discovered Python interpreter at {2}, but future installation of "
u"another Python interpreter could change this. See {3} " u"another Python interpreter could change the meaning of that path. See {3} "
u"for more information." u"for more information."
.format(platform_type, host, found_interpreters[0], .format(platform_type, host, found_interpreters[0],
get_versioned_doclink('reference_appendices/interpreter_discovery.html'))) get_versioned_doclink('reference_appendices/interpreter_discovery.html')))

@ -70,7 +70,7 @@ def test_discovery_interpreter_non_linux():
assert len(mock_action.method_calls) == 2 assert len(mock_action.method_calls) == 2
assert mock_action.method_calls[1][0] == '_discovery_warnings.append' assert mock_action.method_calls[1][0] == '_discovery_warnings.append'
assert u'Platform darwin on host host-fóöbär is using the discovered Python interpreter at /usr/bin/python, ' \ assert u'Platform darwin on host host-fóöbär is using the discovered Python interpreter at /usr/bin/python, ' \
u'but future installation of another Python interpreter could change this' \ u'but future installation of another Python interpreter could change the meaning of that path' \
in mock_action.method_calls[1][1][0] in mock_action.method_calls[1][1][0]

Loading…
Cancel
Save