mirror of
https://github.com/onyx-and-iris/obsws-python.git
synced 2026-04-18 05:53:32 +00:00
import Callable, Iterable from collections.abs instead of typing.
update tests to reflect changes in the API. reorganise hatch envs add black,isort configs to pyproject.toml add pre-commit config
This commit is contained in:
@@ -96,10 +96,8 @@ class ObsClient:
|
||||
|
||||
auth = base64.b64encode(
|
||||
hashlib.sha256(
|
||||
(
|
||||
secret
|
||||
+ self.server_hello["d"]["authentication"]["challenge"].encode()
|
||||
)
|
||||
secret
|
||||
+ self.server_hello["d"]["authentication"]["challenge"].encode()
|
||||
).digest()
|
||||
).decode()
|
||||
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
from typing import Callable, Iterable, Union
|
||||
from collections.abc import Callable, Iterable
|
||||
from typing import Union
|
||||
|
||||
from .util import as_dataclass, to_camel_case, to_snake_case
|
||||
|
||||
|
||||
@@ -42,7 +42,7 @@ class ReqClient:
|
||||
|
||||
def __str__(self):
|
||||
return type(self).__name__
|
||||
|
||||
|
||||
def disconnect(self):
|
||||
self.base_client.ws.close()
|
||||
|
||||
@@ -438,7 +438,7 @@ class ReqClient:
|
||||
|
||||
def set_record_directory(self, recordDirectory):
|
||||
"""
|
||||
Sets the current directory that the record output writes files to.
|
||||
Sets the current directory that the record output writes files to.
|
||||
IMPORTANT NOTE: Requires obs websocket v5.3 or higher.
|
||||
|
||||
:param recordDirectory: Output directory
|
||||
@@ -448,7 +448,7 @@ class ReqClient:
|
||||
"recordDirectory": recordDirectory,
|
||||
}
|
||||
return self.send("SetRecordDirectory", payload)
|
||||
|
||||
|
||||
def get_source_active(self, name):
|
||||
"""
|
||||
Gets the active and show state of a source
|
||||
|
||||
Reference in New Issue
Block a user