You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
After upgrading salt master and minions to 3006.0 some states consistently fails to apply with exceptions like RuntimeError: IOLoop is already running, AttributeError: 'NoneType' object has no attribute 'done', TypeError: object of type 'NoneType' has no len().
Setup
Master running on Debian 11 "bullseye" amd64. Minions - Debian 11, RHEL 8 (still testing other platforms).
VM running on a cloud service, please be explicit and add details
# salt-call state.show_sls chrony
[ERROR ] Rendering exception occurred
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 6, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 457, in run_sync
if not future_cell[0].done():
AttributeError: 'NoneType' object has no attribute 'done'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 218, in render_tmpl
output = render_str(tmplstr, context, tmplpath)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 515, in render_jinja_tmpl
raise SaltRenderError(
salt.exceptions.SaltRenderError: Jinja error: 'NoneType' object has no attribute 'done'
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 6, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 457, in run_sync
if not future_cell[0].done():
AttributeError: 'NoneType' object has no attribute 'done'
; line 6
---
# -*- coding: utf-8 -*-
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
chrony-package-install-pkg-installed:
pkg.installed:
- name: {{ chrony.package }}
[...]
---
[CRITICAL] Rendering SLS 'base:chrony.package.install' failed: Jinja error: 'NoneType' object has no attribute 'done'
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 6, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 457, in run_sync
if not future_cell[0].done():
AttributeError: 'NoneType' object has no attribute 'done'
; line 6
---
# -*- coding: utf-8 -*-
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
chrony-package-install-pkg-installed:
pkg.installed:
- name: {{ chrony.package }}
[...]
---
[ERROR ] Rendering exception occurred
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 7, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 454, in run_sync
self.start()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 804, in start
ncallbacks = len(self._callbacks)
TypeError: object of type 'NoneType' has no len()
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 218, in render_tmpl
output = render_str(tmplstr, context, tmplpath)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 515, in render_jinja_tmpl
raise SaltRenderError(
salt.exceptions.SaltRenderError: Jinja error: object of type 'NoneType' has no len()
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 7, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 454, in run_sync
self.start()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 804, in start
ncallbacks = len(self._callbacks)
TypeError: object of type 'NoneType' has no len()
; line 7
---
[...]
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- set sls_package_install = tplroot ~ '.package.install' %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
{%- from tplroot ~ "/libtofs.jinja" import files_switch with context %}
include:
- {{ sls_package_install }}
[...]
---
[CRITICAL] Rendering SLS 'base:chrony.config.file' failed: Jinja error: object of type 'NoneType' has no len()
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 7, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 454, in run_sync
self.start()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 804, in start
ncallbacks = len(self._callbacks)
TypeError: object of type 'NoneType' has no len()
; line 7
---
[...]
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- set sls_package_install = tplroot ~ '.package.install' %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
{%- from tplroot ~ "/libtofs.jinja" import files_switch with context %}
include:
- {{ sls_package_install }}
[...]
---
[ERROR ] Rendering exception occurred
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 7, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 454, in run_sync
self.start()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 757, in start
raise RuntimeError("IOLoop is already running")
RuntimeError: IOLoop is already running
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 218, in render_tmpl
output = render_str(tmplstr, context, tmplpath)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 515, in render_jinja_tmpl
raise SaltRenderError(
salt.exceptions.SaltRenderError: Jinja error: IOLoop is already running
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 7, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 454, in run_sync
self.start()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 757, in start
raise RuntimeError("IOLoop is already running")
RuntimeError: IOLoop is already running
; line 7
---
[...]
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- set sls_config_file = tplroot ~ '.config.file' %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
include:
- {{ sls_config_file }}
chrony-service-running-service-running:
[...]
---
[CRITICAL] Rendering SLS 'base:chrony.service.running' failed: Jinja error: IOLoop is already running
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 7, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 454, in run_sync
self.start()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 757, in start
raise RuntimeError("IOLoop is already running")
RuntimeError: IOLoop is already running
; line 7
---
[...]
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- set sls_config_file = tplroot ~ '.config.file' %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
include:
- {{ sls_config_file }}
chrony-service-running-service-running:
[...]
---
local:
- Rendering SLS 'base:chrony.package.install' failed: Jinja error: 'NoneType' object has no attribute 'done'
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 6, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 457, in run_sync
if not future_cell[0].done():
AttributeError: 'NoneType' object has no attribute 'done'
; line 6
---
# -*- coding: utf-8 -*-
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
chrony-package-install-pkg-installed:
pkg.installed:
- name: {{ chrony.package }}
[...]
---
- Rendering SLS 'base:chrony.config.file' failed: Jinja error: object of type 'NoneType' has no len()
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 7, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 454, in run_sync
self.start()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 804, in start
ncallbacks = len(self._callbacks)
TypeError: object of type 'NoneType' has no len()
; line 7
---
[...]
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- set sls_package_install = tplroot ~ '.package.install' %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
{%- from tplroot ~ "/libtofs.jinja" import files_switch with context %}
include:
- {{ sls_package_install }}
[...]
---
- Rendering SLS 'base:chrony.service.running' failed: Jinja error: IOLoop is already running
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 7, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 454, in run_sync
self.start()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 757, in start
raise RuntimeError("IOLoop is already running")
RuntimeError: IOLoop is already running
; line 7
---
[...]
# vim: ft=sls
{#- Get the `tplroot` from `tpldir` #}
{%- set tplroot = tpldir.split('/')[0] %}
{%- set sls_config_file = tplroot ~ '.config.file' %}
{%- from tplroot ~ "/map.jinja" import chrony with context %} <======================
include:
- {{ sls_config_file }}
chrony-service-running-service-running:
[...]
---
Expected behavior
Templates render without issues, states applies flawlessly as in 3004/3005.
Versions Report
salt --versions-report
# salt --versions-reportSalt Version:
Salt: 3006.0Python Version:
Python: 3.10.11 (main, Apr 14 2023, 05:57:16) [GCC 11.2.0]Dependency Versions:
cffi: 1.15.1cherrypy: unknowndateutil: 2.8.2docker-py: Not Installedgitdb: Not Installedgitpython: Not InstalledJinja2: 3.1.2libgit2: 1.3.0looseversion: 1.0.2M2Crypto: Not InstalledMako: Not Installedmsgpack: 1.0.2msgpack-pure: Not Installedmysql-python: Not Installedpackaging: 22.0pycparser: 2.21pycrypto: Not Installedpycryptodome: 3.9.8pygit2: 1.7.0python-gnupg: 0.4.8PyYAML: 5.4.1PyZMQ: 23.2.0relenv: 0.11.2smmap: Not Installedtimelib: 0.2.4Tornado: 4.5.3ZMQ: 4.3.4System Versions:
dist: debian 11 bullseyelocale: utf-8machine: x86_64release: 5.10.0-21-cloud-amd64system: Linuxversion: Debian GNU/Linux 11 bullseye
# salt-call state.show_sls postfix.config
[ERROR ] Rendering exception occurred
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 1, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 457, in run_sync
if not future_cell[0].done():
AttributeError: 'NoneType' object has no attribute 'done'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 218, in render_tmpl
output = render_str(tmplstr, context, tmplpath)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 515, in render_jinja_tmpl
raise SaltRenderError(
salt.exceptions.SaltRenderError: Jinja error: 'NoneType' object has no attribute 'done'
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 1, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 457, in run_sync
if not future_cell[0].done():
AttributeError: 'NoneType' object has no attribute 'done'
; line 1
---
{% from "postfix/map.jinja" import postfix with context %} <======================
{%- if grains.os_family == "Suse" %}
# The existence of this file prevents the system to
# overwrite files from salt when installing.
postfix-init-file-managed-postfix.configured:
[...]
---
[CRITICAL] Rendering SLS 'base:postfix' failed: Jinja error: 'NoneType' object has no attribute 'done'
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 1, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 457, in run_sync
if not future_cell[0].done():
AttributeError: 'NoneType' object has no attribute 'done'
; line 1
---
{% from "postfix/map.jinja" import postfix with context %} <======================
{%- if grains.os_family == "Suse" %}
# The existence of this file prevents the system to
# overwrite files from salt when installing.
postfix-init-file-managed-postfix.configured:
[...]
---
local:
- Rendering SLS 'base:postfix' failed: Jinja error: 'NoneType' object has no attribute 'done'
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/templates.py", line 471, in render_jinja_tmpl
output = template.render(**decoded_context)
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render
self.environment.handle_exception()
File "/opt/saltstack/salt/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception
raise rewrite_traceback_stack(source=source)
File "<template>", line 1, in top-level template code
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 185, in get_source
self.check_cache(_template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 138, in check_cache
ret = self.cache_file(template)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/jinja.py", line 131, in cache_file
return fcl.get_file(saltpath, "", True, self.saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1167, in get_file
hash_server, stat_server = self.hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1414, in hash_and_stat_file
hash_result = self.hash_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1407, in hash_file
return self.__hash_and_stat_file(path, saltenv)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/fileclient.py", line 1399, in __hash_and_stat_file
return self.channel.send(load)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 125, in wrap
raise exc_info[1].with_traceback(exc_info[2])
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/asynchronous.py", line 131, in _target
result = io_loop.run_sync(lambda: getattr(self.obj, key)(*args, **kwargs))
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/ext/tornado/ioloop.py", line 457, in run_sync
if not future_cell[0].done():
AttributeError: 'NoneType' object has no attribute 'done'
; line 1
---
{% from "postfix/map.jinja" import postfix with context %} <======================
{%- if grains.os_family == "Suse" %}
# The existence of this file prevents the system to
# overwrite files from salt when installing.
postfix-init-file-managed-postfix.configured:
[...]
---
The text was updated successfully, but these errors were encountered:
Description
After upgrading salt master and minions to 3006.0 some states consistently fails to apply with exceptions like
RuntimeError: IOLoop is already running
,AttributeError: 'NoneType' object has no attribute 'done'
,TypeError: object of type 'NoneType' has no len()
.Setup
Master running on Debian 11 "bullseye" amd64. Minions - Debian 11, RHEL 8 (still testing other platforms).
Steps to Reproduce the behavior
Could be reproduced with community formulas like https://github.com/saltstack-formulas/chrony-formula even on a single instance of Debian 11 running salt-master + salt-minion.
Example pillar:
Trying to render template:
Expected behavior
Templates render without issues, states applies flawlessly as in 3004/3005.
Versions Report
salt --versions-report
Additional context
https://github.com/saltstack-formulas/postfix-formula also triggers the same error; both formulas are used through gitfs via pygit2 provider:
The text was updated successfully, but these errors were encountered: