@scrypted/server 0.94.35 → 0.94.37

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 CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scrypted/server",
3
- "version": "0.94.35",
3
+ "version": "0.94.37",
4
4
  "description": "",
5
5
  "dependencies": {
6
6
  "@mapbox/node-pre-gyp": "^1.0.11",
@@ -20,7 +20,7 @@
20
20
  "node-dijkstra": "^2.5.0",
21
21
  "node-forge": "^1.3.1",
22
22
  "node-gyp": "^10.0.1",
23
- "py": "npm:@bjia56/portable-python@^0.1.23",
23
+ "py": "npm:@bjia56/portable-python@^0.1.26",
24
24
  "router": "^1.3.8",
25
25
  "semver": "^7.6.0",
26
26
  "sharp": "^0.33.2",
@@ -10,6 +10,7 @@ import prompt_toolkit.application.current
10
10
  import prompt_toolkit.key_binding.key_processor
11
11
  import prompt_toolkit.contrib.telnet.server
12
12
  from prompt_toolkit.contrib.telnet.server import TelnetServer, TelnetConnection
13
+ from prompt_toolkit.output.color_depth import ColorDepth
13
14
  from prompt_toolkit.shortcuts import clear_title, set_title
14
15
  from ptpython.repl import embed, PythonRepl, _has_coroutine_flag
15
16
  import ptpython.key_bindings
@@ -29,6 +30,10 @@ from scrypted_python.scrypted_sdk import ScryptedStatic, ScryptedDevice
29
30
  from rpc import maybe_await
30
31
 
31
32
 
33
+ # Our client is xtermjs, so no need to perform any color depth detection
34
+ ColorDepth.default = lambda *args, **kwargs: ColorDepth.DEPTH_4_BIT
35
+
36
+
32
37
  # This section is a bit of a hack - prompt_toolkit has many assumptions
33
38
  # that there is only one global Application, so multiple REPLs will confuse
34
39
  # the library. The patches here allow us to scope a particular call stack
@@ -267,6 +272,7 @@ async def createREPLServer(sdk: ScryptedStatic, plugin: ScryptedDevice) -> int:
267
272
 
268
273
  # we're not in the main loop, so can't handle any signals anyways
269
274
  repl_loop.add_signal_handler = lambda sig, cb: None
275
+ repl_loop.remove_signal_handler = lambda sig: True
270
276
 
271
277
  def finish_setup():
272
278
  telnet_port, exit_server = server_started_future.result()