mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Coerce string when calling compile_template_str
Previously on python3 this would otherwise pass bytes (unhandled)
This commit is contained in:
parent
fef7669a15
commit
958c630e5c
1 changed files with 2 additions and 1 deletions
|
@ -158,6 +158,7 @@ import salt.utils.path
|
|||
import salt.utils.stringio
|
||||
import salt.template
|
||||
from salt.ext import six
|
||||
from salt.utils.stringutils import to_str
|
||||
|
||||
# Set up logging
|
||||
log = logging.getLogger(__name__)
|
||||
|
@ -251,7 +252,7 @@ def _construct_pillar(top_dir,
|
|||
else:
|
||||
data = contents
|
||||
if template is True:
|
||||
data = salt.template.compile_template_str(template=contents,
|
||||
data = salt.template.compile_template_str(template=to_str(contents),
|
||||
renderers=renderers,
|
||||
default=render_default,
|
||||
blacklist=renderer_blacklist,
|
||||
|
|
Loading…
Add table
Reference in a new issue