Skip to content

Commit

Permalink
Fixed shell interpulation TypeError
Browse files Browse the repository at this point in the history
check_output returns a byte string and we need a character (Unicode) string for replace to work
  • Loading branch information
eranco74 committed Aug 24, 2021
1 parent d2e47ce commit 2fb4761
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion skipper/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def _normalize_config(config, normalized_config):

def _interpolate_env_vars(key):
for match in findall(r'\$\(.+\)', key):
output = check_output("echo " + match, shell=True).strip()
output = check_output("echo " + match, shell=True).strip().decode("utf-8")
if not output:
raise ValueError(match)
key = key.replace(match, output)
Expand Down

0 comments on commit 2fb4761

Please sign in to comment.