Skip to content

Incorrect documented return type for Container.top() #2958

@macdjord

Description

@macdjord

The documentation for Container.top() consistently claims that it returns a string. It does not; instead it returns a parsed JSON object which looks like this:

{
    "Processes": [
        [
            "centos",
            "65436",
            "65386",
            "0",
            "21:38",
            "?",
            "00:00:01",
            "python3 /home/foo/baz.py"
        ],
        [
            "centos",
            "65786",
            "65436",
            "0",
            "21:38",
            "?",
            "00:00:00",
            "/usr/local/bin/python3 /home/foo/bar.py"
        ]
    ],
    "Titles": ["UID", "PID", "PPID", "C", "STIME", "TTY", "TIME", "CMD"]
}

Note: I've only tested this in version 4.2.0, but it appears to remain true in the current version of the code.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions