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
Description
Running salt commands against a master that isn't started throws an ugly stacktrace. This seems to only happen on Windows. I tested on ubuntu and there is no stacktrace.
Setup
Install Salt
Don't start the master or stop the master from running
Please be as specific as possible and give set-up details.
on-prem machine
VM (Virtualbox, KVM, etc. please specify)
VM running on a cloud service, please be explicit and add details
container (Kubernetes, Docker, containerd, etc. please specify)
or a combination, please be explicit
jails if it is FreeBSD
classic packaging
onedir packaging
used bootstrap to install
Steps to Reproduce the behavior
Run a salt command:
salt * test.ping
Expected behavior
No stacktrace, just a warning about the master not responding
Screenshots
(venv) PS C:\src\salt> salt * test.ping
[WARNING ] TCP Publish Client encountered an exception while connecting to 127.0.0.1:4512: TimeoutError(), will reconnect in 1 seconds - File "C:\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Python310\lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "C:\src\salt\venv\Scripts\salt.exe\__main__.py", line 7, in <module>
sys.exit(salt_main())
File "C:\src\salt\salt\scripts.py", line 532, in salt_main
client.run()
File "C:\src\salt\salt\cli\salt.py", line 192, in run
for full_ret in cmd_func(**kwargs):
File "C:\src\salt\salt\client\__init__.py", line 816, in cmd_cli
self.pub_data = self.run_job(
File "C:\src\salt\salt\client\__init__.py", line 388, in run_job
pub_data = self.pub(
File "C:\src\salt\salt\client\__init__.py", line 1905, in pub
if listen and not self.event.connect_pub(timeout=timeout):
File "C:\src\salt\salt\utils\event.py", line 323, in connect_pub
self.subscriber = salt.utils.asynchronous.SyncWrapper(
File "C:\src\salt\salt\utils\asynchronous.py", line 77, in __init__
self.obj = cls(*args, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 210, in ipc_publish_client
return publish_client(opts, io_loop, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 152, in publish_client
return salt.transport.tcp.PublishClient(
File "C:\src\salt\salt\transport\tcp.py", line 219, in __init__
super().__init__(opts, io_loop, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 398, in __init__
super().__init__()
[WARNING ] TCP Publish Client encountered an exception while connecting to 127.0.0.1:4512: TimeoutError(), will reconnect in 1 seconds - File "C:\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Python310\lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "C:\src\salt\venv\Scripts\salt.exe\__main__.py", line 7, in <module>
sys.exit(salt_main())
File "C:\src\salt\salt\scripts.py", line 532, in salt_main
client.run()
File "C:\src\salt\salt\cli\salt.py", line 192, in run
for full_ret in cmd_func(**kwargs):
File "C:\src\salt\salt\client\__init__.py", line 816, in cmd_cli
self.pub_data = self.run_job(
File "C:\src\salt\salt\client\__init__.py", line 388, in run_job
pub_data = self.pub(
File "C:\src\salt\salt\client\__init__.py", line 1905, in pub
if listen and not self.event.connect_pub(timeout=timeout):
File "C:\src\salt\salt\utils\event.py", line 323, in connect_pub
self.subscriber = salt.utils.asynchronous.SyncWrapper(
File "C:\src\salt\salt\utils\asynchronous.py", line 77, in __init__
self.obj = cls(*args, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 210, in ipc_publish_client
return publish_client(opts, io_loop, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 152, in publish_client
return salt.transport.tcp.PublishClient(
File "C:\src\salt\salt\transport\tcp.py", line 219, in __init__
super().__init__(opts, io_loop, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 398, in __init__
super().__init__()
[WARNING ] TCP Publish Client encountered an exception while connecting to 127.0.0.1:4512: TimeoutError(), will reconnect in 1 seconds - File "C:\Python310\lib\runpy.py", line 196, in _run_module_as_main
return _run_code(code, main_globals, None,
File "C:\Python310\lib\runpy.py", line 86, in _run_code
exec(code, run_globals)
File "C:\src\salt\venv\Scripts\salt.exe\__main__.py", line 7, in <module>
sys.exit(salt_main())
File "C:\src\salt\salt\scripts.py", line 532, in salt_main
client.run()
File "C:\src\salt\salt\cli\salt.py", line 192, in run
for full_ret in cmd_func(**kwargs):
File "C:\src\salt\salt\client\__init__.py", line 816, in cmd_cli
self.pub_data = self.run_job(
File "C:\src\salt\salt\client\__init__.py", line 388, in run_job
pub_data = self.pub(
File "C:\src\salt\salt\client\__init__.py", line 1905, in pub
if listen and not self.event.connect_pub(timeout=timeout):
File "C:\src\salt\salt\utils\event.py", line 323, in connect_pub
self.subscriber = salt.utils.asynchronous.SyncWrapper(
File "C:\src\salt\salt\utils\asynchronous.py", line 77, in __init__
self.obj = cls(*args, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 210, in ipc_publish_client
return publish_client(opts, io_loop, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 152, in publish_client
return salt.transport.tcp.PublishClient(
File "C:\src\salt\salt\transport\tcp.py", line 219, in __init__
super().__init__(opts, io_loop, **kwargs)
File "C:\src\salt\salt\transport\base.py", line 398, in __init__
super().__init__()
[ERROR ] Request client send timedout
Salt request timed out. The master is not responding. You may need to run your command with `--async` in order to bypass the congested event bus. With `--async`, the CLI tool will print the job id (jid) and exit immediately without listening for responses. You can then use `salt-run jobs.lookup_jid` to look up the results of the job in the job cache later.
Versions Report
salt --versions-report
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)
Head of 3007.x
Salt Version:
Salt: 3007.0rc1+295.g9777612cfdfPython Version:
Python: 3.10.11 (tags/v3.10.11:7d4cc5a, Apr 5 2023, 00:38:17) [MSC v.1929 64 bit (AMD64)]Dependency Versions:
cffi: 1.16.0cherrypy: unknowndateutil: 2.8.2docker-py: Not Installedgitdb: Not Installedgitpython: Not InstalledJinja2: 3.1.3libgit2: Not Installedlooseversion: 1.3.0M2Crypto: Not InstalledMako: Not Installedmsgpack: 1.0.7msgpack-pure: Not Installedmysql-python: Not Installedpackaging: 23.1pycparser: 2.21pycrypto: Not Installedpycryptodome: 3.19.1pygit2: Not Installedpython-gnupg: 0.5.1PyYAML: 6.0.1PyZMQ: 25.1.1relenv: Not Installedsmmap: Not Installedtimelib: 0.3.0Tornado: 6.3.3ZMQ: 4.3.4Salt Package Information:
Package Type: pipSystem Versions:
dist:
locale: utf-8machine: AMD64release: 10system: Windowsversion: 10 10.0.22631 SP0 Multiprocessor Free```</details>
The text was updated successfully, but these errors were encountered:
Description
Running salt commands against a master that isn't started throws an ugly stacktrace. This seems to only happen on Windows. I tested on ubuntu and there is no stacktrace.
Setup
Install Salt
Don't start the master or stop the master from running
Please be as specific as possible and give set-up details.
Steps to Reproduce the behavior
Run a salt command:
Expected behavior
No stacktrace, just a warning about the master not responding
Screenshots
Versions Report
salt --versions-report
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)Head of 3007.x
The text was updated successfully, but these errors were encountered: