saltstack / saltstack/salt

zpool.list parsable argument does nothing

Open
#61,711 7 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug FreeBSD solaris
Dominant language
Python
Stars
15.7k
Forks
5.6k
Avg merge
2d 44m
Merged PRs (30d)
80

Description

Description
Output from the zpool.list command is identical no matter what the parsable argument is set to.

Setup
Running salt-call locally on a SPARC/Solaris minion machine.

  • 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

Steps to Reproduce the behavior

# salt-call zpool.list parsable=True
local:
    ----------
    orapool:
        ----------
        size:
            199G
        alloc:
            50.4G
        free:
            149G
        cap:
            25%
        health:
            ONLINE
    rpool:
        ----------
        size:
            49.8G
        alloc:
            23.1G
        free:
            26.6G
        cap:
            46%
        health:
            ONLINE
    swappool:
        ----------
        size:
            49.8G
        alloc:
            32G
        free:
            17.7G
        cap:
            64%
        health:
            ONLINE

# salt-call zpool.list parsable=False
local:
    ----------
    orapool:
        ----------
        size:
            199G
        alloc:
            50.4G
        free:
            149G
        cap:
            25%
        health:
            ONLINE
    rpool:
        ----------
        size:
            49.8G
        alloc:
            23.1G
        free:
            26.6G
        cap:
            46%
        health:
            ONLINE
    swappool:
        ----------
        size:
            49.8G
        alloc:
            32G
        free:
            17.7G
        cap:
            64%
        health:
            ONLINE

Expected behavior
What the documentation says:

display numbers in parsable (exact) values

Versions Report

salt --versions-report (Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)
Salt Version:
          Salt: 3004

Dependency Versions:
          cffi: 1.14.0
      cherrypy: 15.0.0
      dateutil: 2.8.2
     docker-py: Not Installed
         gitdb: Not Installed
     gitpython: Not Installed
        Jinja2: 3.0.2
       libgit2: Not Installed
      M2Crypto: Not Installed
          Mako: 1.1.2
       msgpack: 1.0.2
  msgpack-pure: Not Installed
  mysql-python: Not Installed
     pycparser: 2.20
      pycrypto: Not Installed
  pycryptodome: 3.11.0
        pygit2: Not Installed
        Python: 3.7.10 (default, Sep 29 2021, 05:44:44)
  python-gnupg: Not Installed
        PyYAML: 6.0
         PyZMQ: 21.0.2
         smmap: Not Installed
       timelib: Not Installed
       Tornado: 4.5.3
           ZMQ: 4.3.4

System Versions:
          dist: solaris 11.4
        locale: utf-8
       machine: sun4v
       release: 5.11
        system: SunOS
       version: Oracle Solaris 11.4

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the salt.modules.zpool.list_ entry point documented for the zpool.list command and reproduce the behavior with salt-call on Solaris using parsable=True and parsable=False. Trace how the parsable argument is handled and verify that the two modes produce the documented exact-value difference.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
devops, operating-systems
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.