Misc cleanup (#494)

* misc cleanup

* Fix dependencies
This commit is contained in:
Matthew Tancik authored and GitHub committed 2022-09-20 09:14:37 -07:00
1 parent 46ac2fcf46
commit 046b5c216b
11 files changed
+59 -57

No files matched your search

+2 -2
View File
@@ -18,7 +18,7 @@
import logging
import signal
import sys
from typing import Dict, Optional
from typing import Dict, Optional, Union
import msgpack
import msgpack_numpy
@@ -116,7 +116,7 @@ class Viewer:
def __repr__(self):
return f"<Viewer using: {self.window} at path: {self.path}>"
def write(self, data: Optional[Dict] = None):
def write(self, data: Union[Dict, str, None] = None):
"""Write data."""
path = self.path.lower()
return self.window.send({"type": "write", "path": path, "data": data})