pydoll-python 2.2.2__tar.gz → 2.2.3__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.
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/PKG-INFO +2 -4
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/chromium/base.py +5 -4
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/tab.py +10 -4
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/dom/types.py +11 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/utils.py +2 -1
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pyproject.toml +2 -3
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/LICENSE +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/README.md +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/chromium/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/chromium/chrome.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/chromium/edge.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/interfaces.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/managers/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/managers/browser_options_manager.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/managers/browser_process_manager.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/managers/proxy_manager.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/managers/temp_dir_manager.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/options.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/browser_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/dom_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/fetch_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/input_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/network_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/page_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/runtime_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/storage_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/commands/target_commands.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/connection/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/connection/connection_handler.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/connection/managers/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/connection/managers/commands_manager.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/connection/managers/events_manager.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/constants.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/elements/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/elements/mixins/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/elements/mixins/find_elements_mixin.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/elements/web_element.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/exceptions.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/base.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/browser/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/browser/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/browser/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/browser/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/browser/responses.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/browser/types.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/dom/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/dom/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/dom/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/dom/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/dom/responses.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/fetch/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/fetch/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/fetch/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/fetch/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/fetch/responses.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/fetch/types.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/input/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/input/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/input/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/input/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/input/types.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/network/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/network/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/network/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/network/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/network/responses.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/network/types.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/page/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/page/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/page/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/page/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/page/responses.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/page/types.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/runtime/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/runtime/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/runtime/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/runtime/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/runtime/responses.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/runtime/types.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/storage/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/storage/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/storage/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/storage/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/storage/responses.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/storage/types.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/target/__init__.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/target/events.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/target/methods.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/target/params.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/target/responses.py +0 -0
- {pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/protocol/target/types.py +0 -0
|
@@ -1,18 +1,16 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: pydoll-python
|
|
3
|
-
Version: 2.2.
|
|
3
|
+
Version: 2.2.3
|
|
4
4
|
Summary:
|
|
5
5
|
Author: Thalison Fernandes
|
|
6
6
|
Author-email: thalissfernandes99@gmail.com
|
|
7
|
-
Requires-Python: >=3.
|
|
7
|
+
Requires-Python: >=3.11,<4.0
|
|
8
8
|
Classifier: Programming Language :: Python :: 3
|
|
9
|
-
Classifier: Programming Language :: Python :: 3.10
|
|
10
9
|
Classifier: Programming Language :: Python :: 3.11
|
|
11
10
|
Classifier: Programming Language :: Python :: 3.12
|
|
12
11
|
Classifier: Programming Language :: Python :: 3.13
|
|
13
12
|
Requires-Dist: aiofiles (>=23.2.1,<24.0.0)
|
|
14
13
|
Requires-Dist: aiohttp (>=3.9.5,<4.0.0)
|
|
15
|
-
Requires-Dist: mkdocstrings (>=0.29.1,<0.30.0)
|
|
16
14
|
Requires-Dist: websockets (>=13.1,<14.0)
|
|
17
15
|
Description-Content-Type: text/markdown
|
|
18
16
|
|
|
@@ -231,12 +231,13 @@ class Browser(ABC): # noqa: PLR0904
|
|
|
231
231
|
"""
|
|
232
232
|
targets = await self.get_targets()
|
|
233
233
|
valid_tab_targets = [
|
|
234
|
-
target
|
|
235
|
-
|
|
234
|
+
target
|
|
235
|
+
for target in targets
|
|
236
|
+
if target['type'] == 'page' and 'extension' not in target['url']
|
|
236
237
|
]
|
|
237
238
|
return [
|
|
238
|
-
Tab(self, self._connection_port, target['targetId'])
|
|
239
|
-
in reversed(valid_tab_targets)
|
|
239
|
+
Tab(self, self._connection_port, target['targetId'])
|
|
240
|
+
for target in reversed(valid_tab_targets)
|
|
240
241
|
]
|
|
241
242
|
|
|
242
243
|
async def set_download_path(self, path: str, browser_context_id: Optional[str] = None):
|
|
@@ -41,6 +41,7 @@ from pydoll.exceptions import (
|
|
|
41
41
|
WaitElementTimeout,
|
|
42
42
|
)
|
|
43
43
|
from pydoll.protocol.base import Response
|
|
44
|
+
from pydoll.protocol.dom.types import EventFileChooserOpened
|
|
44
45
|
from pydoll.protocol.network.responses import GetResponseBodyResponse
|
|
45
46
|
from pydoll.protocol.network.types import Cookie, CookieParam, NetworkLog
|
|
46
47
|
from pydoll.protocol.page.events import PageEvent
|
|
@@ -678,10 +679,11 @@ class Tab(FindElementsMixin): # noqa: PLR0904
|
|
|
678
679
|
files: File path(s) for upload.
|
|
679
680
|
"""
|
|
680
681
|
|
|
681
|
-
async def event_handler(event):
|
|
682
|
+
async def event_handler(event: EventFileChooserOpened):
|
|
683
|
+
file_list = [str(file) for file in files] if isinstance(files, list) else [str(files)]
|
|
682
684
|
await self._execute_command(
|
|
683
|
-
DomCommands.
|
|
684
|
-
files=
|
|
685
|
+
DomCommands.set_file_input_files(
|
|
686
|
+
files=file_list,
|
|
685
687
|
backend_node_id=event['params']['backendNodeId'],
|
|
686
688
|
)
|
|
687
689
|
)
|
|
@@ -695,7 +697,11 @@ class Tab(FindElementsMixin): # noqa: PLR0904
|
|
|
695
697
|
if self.intercept_file_chooser_dialog_enabled is False:
|
|
696
698
|
await self.enable_intercept_file_chooser_dialog()
|
|
697
699
|
|
|
698
|
-
await self.on(
|
|
700
|
+
await self.on(
|
|
701
|
+
PageEvent.FILE_CHOOSER_OPENED,
|
|
702
|
+
cast(Callable[[dict], Any], event_handler),
|
|
703
|
+
temporary=True,
|
|
704
|
+
)
|
|
699
705
|
|
|
700
706
|
yield
|
|
701
707
|
|
|
@@ -79,3 +79,14 @@ class BoxModel(TypedDict):
|
|
|
79
79
|
width: int
|
|
80
80
|
height: int
|
|
81
81
|
shapeOutside: NotRequired[ShapeOutsideInfo]
|
|
82
|
+
|
|
83
|
+
|
|
84
|
+
class EventFileChooserOpenedParams(TypedDict):
|
|
85
|
+
frameId: str
|
|
86
|
+
mode: str
|
|
87
|
+
backendNodeId: int
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
class EventFileChooserOpened(TypedDict):
|
|
91
|
+
method: str
|
|
92
|
+
params: EventFileChooserOpenedParams
|
|
@@ -19,11 +19,12 @@ class TextExtractor(HTMLParser):
|
|
|
19
19
|
Extracts visible text content from an HTML string, excluding the contents of
|
|
20
20
|
tags specified in _skip_tags.
|
|
21
21
|
"""
|
|
22
|
+
|
|
22
23
|
def __init__(self):
|
|
23
24
|
super().__init__()
|
|
24
25
|
self._parts = []
|
|
25
26
|
self._skip = False
|
|
26
|
-
self._skip_tags = {
|
|
27
|
+
self._skip_tags = {'script', 'style', 'template'}
|
|
27
28
|
|
|
28
29
|
def handle_starttag(self, tag, attrs):
|
|
29
30
|
"""
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[tool.poetry]
|
|
2
2
|
name = "pydoll-python"
|
|
3
|
-
version = "2.2.
|
|
3
|
+
version = "2.2.3"
|
|
4
4
|
description = ""
|
|
5
5
|
authors = ["Thalison Fernandes <thalissfernandes99@gmail.com>"]
|
|
6
6
|
readme = "README.md"
|
|
@@ -9,11 +9,10 @@ packages = [
|
|
|
9
9
|
]
|
|
10
10
|
|
|
11
11
|
[tool.poetry.dependencies]
|
|
12
|
-
python = "^3.
|
|
12
|
+
python = "^3.11"
|
|
13
13
|
websockets = "^13.1"
|
|
14
14
|
aiohttp = "^3.9.5"
|
|
15
15
|
aiofiles = "^23.2.1"
|
|
16
|
-
mkdocstrings = "^0.29.1"
|
|
17
16
|
|
|
18
17
|
|
|
19
18
|
[tool.poetry.group.dev.dependencies]
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/managers/browser_options_manager.py
RENAMED
|
File without changes
|
{pydoll_python-2.2.2 → pydoll_python-2.2.3}/pydoll/browser/managers/browser_process_manager.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|