Compare commits
3 Commits
master
...
27-fix-htt
Author | SHA1 | Date | |
---|---|---|---|
fdcd67aae6 | |||
799280f074 | |||
202bf85f55 |
@ -1,14 +1,17 @@
|
||||
import shutil
|
||||
import glob
|
||||
import subprocess
|
||||
import pydantic
|
||||
import pathlib
|
||||
import ctypes
|
||||
import os
|
||||
import sys
|
||||
import logging
|
||||
import dataclasses
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
from typing import (overload, Optional, Literal,)
|
||||
from typing import (overload, Optional, Literal, Any, Annotated,)
|
||||
|
||||
from .cli_bootstrap import PyProject
|
||||
|
||||
@ -89,4 +92,31 @@ def runtime_libdirs_init(
|
||||
|
||||
ctypes.cdll.LoadLibrary(preload_found)
|
||||
else:
|
||||
raise NotImplementedError
|
||||
raise NotImplementedError
|
||||
|
||||
class interfaces_index_t:
|
||||
@dataclasses.dataclass
|
||||
class Interface:
|
||||
@dataclasses.dataclass
|
||||
class AddrInfo:
|
||||
family: str
|
||||
local: str
|
||||
|
||||
name: Annotated[
|
||||
str,
|
||||
pydantic.Field(
|
||||
alias='ifname',
|
||||
)
|
||||
]
|
||||
addr_info: list[AddrInfo]
|
||||
|
||||
def interfaces_index() -> list[interfaces_index_t.Interface]:
|
||||
res = pydantic.RootModel[
|
||||
list[interfaces_index_t.Interface]
|
||||
].model_validate_json(
|
||||
subprocess.check_output([
|
||||
'ip', '-j', 'addr',
|
||||
]).decode('utf-8')
|
||||
).root
|
||||
|
||||
return res
|
||||
|
@ -1,6 +1,6 @@
|
||||
[project]
|
||||
name = 'online.fxreader.pr34'
|
||||
version = '0.1.5.9'
|
||||
version = '0.1.5.9+27.1'
|
||||
|
||||
dependencies = [
|
||||
#"-r requirements.txt",
|
||||
|
BIN
releases/whl/online_fxreader_pr34-0.1.5.9+27.1-py3-none-any.whl
(Stored with Git LFS)
Normal file
BIN
releases/whl/online_fxreader_pr34-0.1.5.9+27.1-py3-none-any.whl
(Stored with Git LFS)
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user