streamlit-webrtc 0.47.6__tar.gz → 0.47.7__tar.gz

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.
Files changed (30) hide show
  1. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/PKG-INFO +2 -1
  2. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/README.md +1 -0
  3. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/pyproject.toml +4 -29
  4. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/__init__.py +1 -2
  5. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/components_callbacks.py +7 -1
  6. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/factory.py +6 -12
  7. streamlit_webrtc-0.47.7/streamlit_webrtc/frontend/build/asset-manifest.json +10 -0
  8. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/frontend/build/index.html +1 -1
  9. streamlit_webrtc-0.47.7/streamlit_webrtc/frontend/build/static/js/main.9c17b353.js +3 -0
  10. streamlit_webrtc-0.47.7/streamlit_webrtc/frontend/build/static/js/main.9c17b353.js.map +1 -0
  11. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/mix.py +3 -1
  12. streamlit_webrtc-0.47.6/streamlit_webrtc/frontend/build/asset-manifest.json +0 -10
  13. streamlit_webrtc-0.47.6/streamlit_webrtc/frontend/build/static/js/main.6951f096.js +0 -3
  14. streamlit_webrtc-0.47.6/streamlit_webrtc/frontend/build/static/js/main.6951f096.js.map +0 -1
  15. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/LICENSE +0 -0
  16. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/_compat.py +0 -0
  17. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/component.py +0 -0
  18. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/config.py +0 -0
  19. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/eventloop.py +0 -0
  20. /streamlit_webrtc-0.47.6/streamlit_webrtc/frontend/build/static/js/main.6951f096.js.LICENSE.txt → /streamlit_webrtc-0.47.7/streamlit_webrtc/frontend/build/static/js/main.9c17b353.js.LICENSE.txt +0 -0
  21. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/models.py +0 -0
  22. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/process.py +0 -0
  23. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/py.typed +0 -0
  24. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/receive.py +0 -0
  25. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/relay.py +0 -0
  26. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/server.py +0 -0
  27. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/session_info.py +0 -0
  28. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/shutdown.py +0 -0
  29. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/source.py +0 -0
  30. {streamlit_webrtc-0.47.6 → streamlit_webrtc-0.47.7}/streamlit_webrtc/webrtc.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: streamlit-webrtc
3
- Version: 0.47.6
3
+ Version: 0.47.7
4
4
  Summary:
5
5
  Home-page: https://github.com/whitphx/streamlit-webrtc
6
6
  License: MIT
@@ -26,6 +26,7 @@ Description-Content-Type: text/markdown
26
26
 
27
27
  [![Tests](https://github.com/whitphx/streamlit-webrtc/workflows/Tests/badge.svg?branch=main)](https://github.com/whitphx/streamlit-webrtc/actions?query=workflow%3ATests+branch%3Amain)
28
28
  [![Frontend Tests](https://github.com/whitphx/streamlit-webrtc/workflows/Frontend%20tests/badge.svg?branch=main)](https://github.com/whitphx/streamlit-webrtc/actions?query=workflow%3A%22Frontend+tests%22+branch%3Amain)
29
+ [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
29
30
 
30
31
  [![PyPI](https://img.shields.io/pypi/v/streamlit-webrtc)](https://pypi.org/project/streamlit-webrtc/)
31
32
  [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/streamlit-webrtc)](https://pypi.org/project/streamlit-webrtc/)
@@ -3,6 +3,7 @@
3
3
 
4
4
  [![Tests](https://github.com/whitphx/streamlit-webrtc/workflows/Tests/badge.svg?branch=main)](https://github.com/whitphx/streamlit-webrtc/actions?query=workflow%3ATests+branch%3Amain)
5
5
  [![Frontend Tests](https://github.com/whitphx/streamlit-webrtc/workflows/Frontend%20tests/badge.svg?branch=main)](https://github.com/whitphx/streamlit-webrtc/actions?query=workflow%3A%22Frontend+tests%22+branch%3Amain)
6
+ [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
6
7
 
7
8
  [![PyPI](https://img.shields.io/pypi/v/streamlit-webrtc)](https://pypi.org/project/streamlit-webrtc/)
8
9
  [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/streamlit-webrtc)](https://pypi.org/project/streamlit-webrtc/)
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "streamlit-webrtc"
3
- version = "0.47.6"
3
+ version = "0.47.7"
4
4
  description = ""
5
5
  authors = ["Yuichiro Tsuchiya <t.yic.yt@gmail.com>"]
6
6
  license = "MIT"
@@ -19,10 +19,8 @@ typing_extensions = { version = ">=3.7.4,<5.0.0", python = "<3.8" }
19
19
  packaging = ">=20.0"
20
20
 
21
21
  [tool.poetry.group.dev.dependencies]
22
- black = "^21.12b0"
23
22
  click = ">=7.0,<8.0" # We must specify the click version because we install older versions of Streamlit in the CI process and their depending click version is different from the newer releases.
24
- isort = "^5.10.1"
25
- flake8 = "^5.0.4"
23
+ ruff = ">=0.3,<0.5"
26
24
  mypy = "^1.0.0"
27
25
  pydub = "^0.25.1"
28
26
  matplotlib = "^3.5.1"
@@ -39,31 +37,8 @@ pandas = [
39
37
  streamlit = "^1.13.0"
40
38
  twilio = ">=8.1,<10.0"
41
39
 
42
- [tool.black]
43
- line-length = 88
44
- target-version = ['py38']
45
- exclude = '''
46
-
47
- (
48
- /(
49
- \.eggs # exclude a few common directories in the
50
- | \.git # root of the project
51
- | \.hg
52
- | \.mypy_cache
53
- | \.tox
54
- | \.venv
55
- | _build
56
- | buck-out
57
- | build
58
- | dist
59
- )/
60
- | streamlit_webrtc/frontend
61
- )
62
- '''
63
-
64
- [tool.isort]
65
- # https://pycqa.github.io/isort/docs/configuration/black_compatibility/
66
- profile = "black"
40
+ [tool.ruff.lint]
41
+ extend-select = ["I"]
67
42
 
68
43
  [build-system]
69
44
  requires = ["poetry-core>=1.0.0"]
@@ -1,5 +1,4 @@
1
- """streamlit-webrtc
2
- """
1
+ """streamlit-webrtc"""
3
2
 
4
3
  try:
5
4
  import importlib.metadata as importlib_metadata
@@ -25,8 +25,14 @@ Here's the result when you call Streamlit.setComponentValue():
25
25
  Script begins...
26
26
 
27
27
  """
28
+
28
29
  from streamlit import session_state as _state
29
- from streamlit.components.v1 import components as _components
30
+
31
+ try:
32
+ # Streamlit >= 1.34.0 (Ref: https://github.com/streamlit/streamlit/pull/8457)
33
+ from streamlit.components.v1 import custom_component as _components # type: ignore
34
+ except ImportError:
35
+ from streamlit.components.v1 import components as _components # type: ignore
30
36
 
31
37
 
32
38
  def _patch_register_widget(register_widget):
@@ -63,8 +63,7 @@ def create_process_track(
63
63
  frame_callback: Optional[FrameCallback] = None,
64
64
  queued_frames_callback: Optional[QueuedVideoFramesCallback] = None,
65
65
  on_ended: Optional[MediaEndedCallback] = None,
66
- ) -> AudioProcessTrack[AudioProcessorT]:
67
- ...
66
+ ) -> AudioProcessTrack[AudioProcessorT]: ...
68
67
 
69
68
 
70
69
  @overload
@@ -76,8 +75,7 @@ def create_process_track(
76
75
  frame_callback: Optional[FrameCallback] = None,
77
76
  queued_frames_callback: Optional[QueuedVideoFramesCallback] = None,
78
77
  on_ended: Optional[MediaEndedCallback] = None,
79
- ) -> AsyncAudioProcessTrack[AudioProcessorT]:
80
- ...
78
+ ) -> AsyncAudioProcessTrack[AudioProcessorT]: ...
81
79
 
82
80
 
83
81
  @overload
@@ -89,8 +87,7 @@ def create_process_track(
89
87
  frame_callback: Optional[FrameCallback] = None,
90
88
  queued_frames_callback: Optional[QueuedVideoFramesCallback] = None,
91
89
  on_ended: Optional[MediaEndedCallback] = None,
92
- ) -> VideoProcessTrack[VideoProcessorT]:
93
- ...
90
+ ) -> VideoProcessTrack[VideoProcessorT]: ...
94
91
 
95
92
 
96
93
  @overload
@@ -102,8 +99,7 @@ def create_process_track(
102
99
  frame_callback: Optional[FrameCallback] = None,
103
100
  queued_frames_callback: Optional[QueuedVideoFramesCallback] = None,
104
101
  on_ended: Optional[MediaEndedCallback] = None,
105
- ) -> AsyncVideoProcessTrack[VideoProcessorT]:
106
- ...
102
+ ) -> AsyncVideoProcessTrack[VideoProcessorT]: ...
107
103
 
108
104
 
109
105
  # Overloads for the cases where the processor_factory is NOT specified
@@ -116,8 +112,7 @@ def create_process_track(
116
112
  processor_factory: Literal[None] = None,
117
113
  queued_frames_callback: Optional[QueuedVideoFramesCallback] = None,
118
114
  on_ended: Optional[MediaEndedCallback] = None,
119
- ) -> MediaProcessTrack[CallbackAttachableProcessor[FrameT], FrameT]:
120
- ...
115
+ ) -> MediaProcessTrack[CallbackAttachableProcessor[FrameT], FrameT]: ...
121
116
 
122
117
 
123
118
  @overload
@@ -129,8 +124,7 @@ def create_process_track(
129
124
  async_processing: Literal[True] = True,
130
125
  queued_frames_callback: Optional[QueuedVideoFramesCallback] = None,
131
126
  on_ended: Optional[MediaEndedCallback] = None,
132
- ) -> AsyncMediaProcessTrack[CallbackAttachableProcessor[FrameT], FrameT]:
133
- ...
127
+ ) -> AsyncMediaProcessTrack[CallbackAttachableProcessor[FrameT], FrameT]: ...
134
128
 
135
129
 
136
130
  def create_process_track(
@@ -0,0 +1,10 @@
1
+ {
2
+ "files": {
3
+ "main.js": "./static/js/main.9c17b353.js",
4
+ "index.html": "./index.html",
5
+ "main.9c17b353.js.map": "./static/js/main.9c17b353.js.map"
6
+ },
7
+ "entrypoints": [
8
+ "static/js/main.9c17b353.js"
9
+ ]
10
+ }
@@ -1 +1 @@
1
- <!doctype html><html lang="en"><head><title>Streamlit WebRTC Component</title><meta charset="UTF-8"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Streamlit WebRTC Component"/><script defer="defer" src="./static/js/main.6951f096.js"></script></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div></body></html>
1
+ <!doctype html><html lang="en"><head><title>Streamlit WebRTC Component</title><meta charset="UTF-8"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Streamlit WebRTC Component"/><script defer="defer" src="./static/js/main.9c17b353.js"></script></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div></body></html>