Skip to content
Snippets Groups Projects
Commit 173d185d authored by John Snow's avatar John Snow
Browse files

scripts/qom-fuse: move to python/qemu/qmp/qom_fuse.py


Move qom-fuse over to the python package now that it passes the
linter. Update the import paradigms so that it continues to pass in the
context of the Python package.

Signed-off-by: default avatarJohn Snow <jsnow@redhat.com>
Message-id: 20210603003719.1321369-18-jsnow@redhat.com
Signed-off-by: default avatarJohn Snow <jsnow@redhat.com>
parent c63f3b0b
No related branches found
No related tags found
No related merge requests found
#!/usr/bin/env python3
"""
QEMU Object Model FUSE filesystem tool
......@@ -35,7 +34,6 @@
import argparse
from errno import ENOENT, EPERM
import os
import stat
import sys
from typing import (
......@@ -50,10 +48,8 @@
import fuse
from fuse import FUSE, FuseOSError, Operations
sys.path.append(os.path.join(os.path.dirname(__file__), '..', '..', 'python'))
from qemu.qmp import QMPResponseError
from qemu.qmp.qom_common import QOMCommand
from . import QMPResponseError
from .qom_common import QOMCommand
fuse.fuse_python_api = (0, 2)
......@@ -208,7 +204,3 @@ def readdir(self, path: str, fh: IO[bytes]) -> Iterator[str]:
yield '..'
for item in self.qom_list(path):
yield item.name
if __name__ == '__main__':
sys.exit(QOMFuse.entry_point())
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment