CI: fix the bug returns wrong artifact path when app_name is a subset of a longer one

pull/6192/head
Fu Hanxi 2020-11-11 11:37:57 +08:00
rodzic 971cbbb7f3
commit 5fa935e5ea
1 zmienionych plików z 3 dodań i 1 usunięć

Wyświetl plik

@ -80,7 +80,9 @@ class Artifacts(object):
for artifact_info in artifact_index: for artifact_info in artifact_index:
match_result = True match_result = True
if app_path: if app_path:
match_result = app_path in artifact_info["app_dir"] # We use endswith here to avoid issue like:
# examples_protocols_mqtt_ws but return a examples_protocols_mqtt_wss failure
match_result = artifact_info["app_dir"].endswith(app_path)
if config_name: if config_name:
match_result = match_result and config_name == artifact_info["config"] match_result = match_result and config_name == artifact_info["config"]
if target: if target: