[BUG] virt.get_graphics returns single dictionary
Open
Nobody has claimed this yet.
bug
severity-low
- Dominant language
- Python
- Stars
- 15.7k
- Forks
- 5.6k
- Avg merge
- 2d 44m
- Merged PRs (30d)
- 80
Description
Description
virt.get_graphics returns only single dictionary even if virtual machine has multiple graphics devices.
Steps to Reproduce the behavior
salt 'vmm01*' virt.get_graphics vm-test
vm-test:
----------
autoport:
yes
keymap:
None
listen:
127.0.0.1
port:
5911
type:
vnc
vmm01# virsh dumpxml vm-test
<domain type='kvm' id='42'>
...
<devices>
<graphics type='spice' port='5910' autoport='yes' listen='127.0.0.1'>
<listen type='address' address='127.0.0.1'/>
<image compression='off'/>
</graphics>
<graphics type='vnc' port='5911' autoport='yes' listen='127.0.0.1'>
<listen type='address' address='127.0.0.1'/>
</graphics>
</devices>
...
</domain>
Expected behavior
graphics should be list of dictionaries, the same as it is with nics or disks
Versions Report
salt --versions-report
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)Salt Version:
Salt: 3002.2
Dependency Versions:
cffi: 1.11.5
cherrypy: Not Installed
dateutil: 2.6.1
docker-py: Not Installed
gitdb: Not Installed
gitpython: Not Installed
Jinja2: 2.10.1
libgit2: Not Installed
M2Crypto: 0.35.2
Mako: Not Installed
msgpack: 0.6.2
msgpack-pure: Not Installed
mysql-python: Not Installed
pycparser: 2.14
pycrypto: Not Installed
pycryptodome: Not Installed
pygit2: Not Installed
Python: 3.6.8 (default, Dec 3 2020, 18:11:24)
python-gnupg: Not Installed
PyYAML: 3.12
PyZMQ: 19.0.0
smmap: Not Installed
timelib: Not Installed
Tornado: 4.5.3
ZMQ: 4.3.3
System Versions:
dist: centos 8
locale: UTF-8
machine: x86_64
release: 4.18.0-259.el8.x86_64
system: Linux
version: CentOS Stream 8
Additional context
Add any other context about the problem here.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the virt.get_graphics entry point and compare its result handling with the nics or disks behavior mentioned in the issue. Reproduce the case with multiple graphics devices, then add coverage and verify that the result contains one dictionary per graphics device.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 45/100