mirror of
https://github.com/DarrylNixon/melamine.git
synced 2024-04-22 06:27:20 -07:00
Resolve circular import
This commit is contained in:
parent
cd91b960dd
commit
ffbf73a372
2 changed files with 2 additions and 6 deletions
|
@ -3,8 +3,6 @@ from collections.abc import Generator
|
|||
|
||||
from aiopath import Path
|
||||
|
||||
from melamine.classes import AsyncObject
|
||||
|
||||
|
||||
class ext2_filsys(ctypes.Structure):
|
||||
pass
|
||||
|
@ -57,7 +55,7 @@ class EXT23Handler:
|
|||
self.libext2fs.ext2fs_get_next_inode.argtypes = [ext2_inode_scan, ext2_inode_large_p]
|
||||
self.libext2fs.ext2fs_get_next_inode.restype = ctypes.c_int
|
||||
|
||||
async def get_hardlinks(self, path: AsyncObject) -> Generator:
|
||||
async def get_hardlinks(self, path) -> Generator:
|
||||
fs = ext2_filsys()
|
||||
if self.libext2fs.ext2fs_open(bytes(path.absolute_path), 0, 0, 0, ctypes.byref(fs)) == 0:
|
||||
try:
|
||||
|
|
|
@ -3,14 +3,12 @@ from collections.abc import Generator
|
|||
import libzfs
|
||||
from aiopath import Path
|
||||
|
||||
from melamine.classes import AsyncObject
|
||||
|
||||
|
||||
class ZFSHandler:
|
||||
def __init__(self) -> None:
|
||||
self.fs = "zfs"
|
||||
|
||||
async def get_hardlinks(self, path: AsyncObject) -> Generator:
|
||||
async def get_hardlinks(self, path) -> Generator:
|
||||
path_str = str(path.absolute_path)
|
||||
|
||||
zfs = libzfs.ZFS()
|
||||
|
|
Loading…
Reference in a new issue