@scrypted/server 0.69.0 → 0.70.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/python/plugin_remote.py +8 -16
- package/python/rpc_reader.py +0 -2
package/package.json
CHANGED
package/python/plugin_remote.py
CHANGED
@@ -56,12 +56,10 @@ class SystemDeviceState(TypedDict):
|
|
56
56
|
|
57
57
|
|
58
58
|
class DeviceProxy(object):
|
59
|
-
device: asyncio.Future[rpc.RpcPeer]
|
60
|
-
|
61
59
|
def __init__(self, systemManager: SystemManager, id: str):
|
62
60
|
self.systemManager = systemManager
|
63
61
|
self.id = id
|
64
|
-
self.device = None
|
62
|
+
self.device: asyncio.Future[rpc.RpcPeer] = None
|
65
63
|
|
66
64
|
def __getattr__(self, name):
|
67
65
|
if name == 'id':
|
@@ -95,13 +93,11 @@ class DeviceProxy(object):
|
|
95
93
|
|
96
94
|
|
97
95
|
class SystemManager(scrypted_python.scrypted_sdk.types.SystemManager):
|
98
|
-
deviceProxies: Mapping[str, DeviceProxy]
|
99
|
-
|
100
96
|
def __init__(self, api: Any, systemState: Mapping[str, Mapping[str, SystemDeviceState]]) -> None:
|
101
97
|
super().__init__()
|
102
98
|
self.api = api
|
103
99
|
self.systemState = systemState
|
104
|
-
self.deviceProxies = {}
|
100
|
+
self.deviceProxies: Mapping[str, DeviceProxy] = {}
|
105
101
|
|
106
102
|
async def getComponent(self, id: str) -> Any:
|
107
103
|
return await self.api.getComponent(id)
|
@@ -329,16 +325,12 @@ class DeviceManager(scrypted_python.scrypted_sdk.types.DeviceManager):
|
|
329
325
|
|
330
326
|
|
331
327
|
class PluginRemote:
|
332
|
-
|
333
|
-
|
334
|
-
|
335
|
-
|
336
|
-
|
337
|
-
|
338
|
-
consoles: Mapping[str, Future[Tuple[StreamReader, StreamWriter]]] = {}
|
339
|
-
ptimeSum = 0
|
340
|
-
|
341
|
-
def __init__(self, peer: rpc.RpcPeer, api, pluginId, hostInfo, loop: AbstractEventLoop):
|
328
|
+
def __init__(self, peer: rpc.RpcPeer, api, pluginId: str, hostInfo, loop: AbstractEventLoop):
|
329
|
+
self.systemState: Mapping[str, Mapping[str, SystemDeviceState]] = {}
|
330
|
+
self.nativeIds: Mapping[str, DeviceStorage] = {}
|
331
|
+
self.mediaManager: MediaManager
|
332
|
+
self.consoles: Mapping[str, Future[Tuple[StreamReader, StreamWriter]]] = {}
|
333
|
+
self.ptimeSum = 0
|
342
334
|
self.allMemoryStats = {}
|
343
335
|
self.peer = peer
|
344
336
|
self.api = api
|