parsek-cdp 0.1.0__py3-none-any.whl
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.
- parsek_cdp/__init__.py +55 -0
- parsek_cdp/_logging.py +49 -0
- parsek_cdp/cdp/__init__.py +247 -0
- parsek_cdp/cdp/accessibility/__init__.py +15 -0
- parsek_cdp/cdp/accessibility/events.py +35 -0
- parsek_cdp/cdp/accessibility/functions.py +202 -0
- parsek_cdp/cdp/accessibility/types.py +235 -0
- parsek_cdp/cdp/animation/__init__.py +15 -0
- parsek_cdp/cdp/animation/events.py +52 -0
- parsek_cdp/cdp/animation/functions.py +140 -0
- parsek_cdp/cdp/animation/types.py +113 -0
- parsek_cdp/cdp/audits/__init__.py +15 -0
- parsek_cdp/cdp/audits/events.py +21 -0
- parsek_cdp/cdp/audits/functions.py +95 -0
- parsek_cdp/cdp/audits/types.py +1051 -0
- parsek_cdp/cdp/autofill/__init__.py +15 -0
- parsek_cdp/cdp/autofill/events.py +27 -0
- parsek_cdp/cdp/autofill/functions.py +64 -0
- parsek_cdp/cdp/autofill/types.py +108 -0
- parsek_cdp/cdp/backgroundservice/__init__.py +15 -0
- parsek_cdp/cdp/backgroundservice/events.py +40 -0
- parsek_cdp/cdp/backgroundservice/functions.py +59 -0
- parsek_cdp/cdp/backgroundservice/types.py +63 -0
- parsek_cdp/cdp/bluetoothemulation/__init__.py +15 -0
- parsek_cdp/cdp/bluetoothemulation/events.py +70 -0
- parsek_cdp/cdp/bluetoothemulation/functions.py +247 -0
- parsek_cdp/cdp/bluetoothemulation/types.py +120 -0
- parsek_cdp/cdp/browser/__init__.py +15 -0
- parsek_cdp/cdp/browser/events.py +46 -0
- parsek_cdp/cdp/browser/functions.py +350 -0
- parsek_cdp/cdp/browser/types.py +158 -0
- parsek_cdp/cdp/cachestorage/__init__.py +15 -0
- parsek_cdp/cdp/cachestorage/events.py +13 -0
- parsek_cdp/cdp/cachestorage/functions.py +126 -0
- parsek_cdp/cdp/cachestorage/types.py +89 -0
- parsek_cdp/cdp/cast/__init__.py +15 -0
- parsek_cdp/cdp/cast/events.py +38 -0
- parsek_cdp/cdp/cast/functions.py +77 -0
- parsek_cdp/cdp/cast/types.py +23 -0
- parsek_cdp/cdp/console/__init__.py +15 -0
- parsek_cdp/cdp/console/events.py +22 -0
- parsek_cdp/cdp/console/functions.py +36 -0
- parsek_cdp/cdp/console/types.py +30 -0
- parsek_cdp/cdp/css/__init__.py +15 -0
- parsek_cdp/cdp/css/events.py +79 -0
- parsek_cdp/cdp/css/functions.py +788 -0
- parsek_cdp/cdp/css/types.py +742 -0
- parsek_cdp/cdp/debugger/__init__.py +15 -0
- parsek_cdp/cdp/debugger/events.py +164 -0
- parsek_cdp/cdp/debugger/functions.py +663 -0
- parsek_cdp/cdp/debugger/types.py +171 -0
- parsek_cdp/cdp/deviceaccess/__init__.py +15 -0
- parsek_cdp/cdp/deviceaccess/events.py +30 -0
- parsek_cdp/cdp/deviceaccess/functions.py +54 -0
- parsek_cdp/cdp/deviceaccess/types.py +28 -0
- parsek_cdp/cdp/deviceorientation/__init__.py +15 -0
- parsek_cdp/cdp/deviceorientation/events.py +13 -0
- parsek_cdp/cdp/deviceorientation/functions.py +35 -0
- parsek_cdp/cdp/deviceorientation/types.py +10 -0
- parsek_cdp/cdp/dom/__init__.py +15 -0
- parsek_cdp/cdp/dom/events.py +228 -0
- parsek_cdp/cdp/dom/functions.py +1033 -0
- parsek_cdp/cdp/dom/types.py +293 -0
- parsek_cdp/cdp/domdebugger/__init__.py +15 -0
- parsek_cdp/cdp/domdebugger/events.py +13 -0
- parsek_cdp/cdp/domdebugger/functions.py +155 -0
- parsek_cdp/cdp/domdebugger/types.py +57 -0
- parsek_cdp/cdp/domsnapshot/__init__.py +15 -0
- parsek_cdp/cdp/domsnapshot/events.py +13 -0
- parsek_cdp/cdp/domsnapshot/functions.py +111 -0
- parsek_cdp/cdp/domsnapshot/types.py +312 -0
- parsek_cdp/cdp/domstorage/__init__.py +15 -0
- parsek_cdp/cdp/domstorage/events.py +60 -0
- parsek_cdp/cdp/domstorage/functions.py +79 -0
- parsek_cdp/cdp/domstorage/types.py +30 -0
- parsek_cdp/cdp/emulation/__init__.py +15 -0
- parsek_cdp/cdp/emulation/events.py +17 -0
- parsek_cdp/cdp/emulation/functions.py +688 -0
- parsek_cdp/cdp/emulation/types.py +305 -0
- parsek_cdp/cdp/eventbreakpoints/__init__.py +15 -0
- parsek_cdp/cdp/eventbreakpoints/events.py +13 -0
- parsek_cdp/cdp/eventbreakpoints/functions.py +41 -0
- parsek_cdp/cdp/eventbreakpoints/types.py +10 -0
- parsek_cdp/cdp/extensions/__init__.py +15 -0
- parsek_cdp/cdp/extensions/events.py +13 -0
- parsek_cdp/cdp/extensions/functions.py +118 -0
- parsek_cdp/cdp/extensions/types.py +19 -0
- parsek_cdp/cdp/fedcm/__init__.py +15 -0
- parsek_cdp/cdp/fedcm/events.py +45 -0
- parsek_cdp/cdp/fedcm/functions.py +93 -0
- parsek_cdp/cdp/fedcm/types.py +72 -0
- parsek_cdp/cdp/fetch/__init__.py +15 -0
- parsek_cdp/cdp/fetch/events.py +82 -0
- parsek_cdp/cdp/fetch/functions.py +215 -0
- parsek_cdp/cdp/fetch/types.py +81 -0
- parsek_cdp/cdp/filesystem/__init__.py +15 -0
- parsek_cdp/cdp/filesystem/events.py +13 -0
- parsek_cdp/cdp/filesystem/functions.py +36 -0
- parsek_cdp/cdp/filesystem/types.py +54 -0
- parsek_cdp/cdp/headlessexperimental/__init__.py +15 -0
- parsek_cdp/cdp/headlessexperimental/events.py +13 -0
- parsek_cdp/cdp/headlessexperimental/functions.py +77 -0
- parsek_cdp/cdp/headlessexperimental/types.py +24 -0
- parsek_cdp/cdp/heapprofiler/__init__.py +15 -0
- parsek_cdp/cdp/heapprofiler/events.py +65 -0
- parsek_cdp/cdp/heapprofiler/functions.py +193 -0
- parsek_cdp/cdp/heapprofiler/types.py +57 -0
- parsek_cdp/cdp/indexeddb/__init__.py +15 -0
- parsek_cdp/cdp/indexeddb/events.py +13 -0
- parsek_cdp/cdp/indexeddb/functions.py +232 -0
- parsek_cdp/cdp/indexeddb/types.py +120 -0
- parsek_cdp/cdp/input/__init__.py +15 -0
- parsek_cdp/cdp/input/events.py +25 -0
- parsek_cdp/cdp/input/functions.py +361 -0
- parsek_cdp/cdp/input/types.py +87 -0
- parsek_cdp/cdp/inspector/__init__.py +15 -0
- parsek_cdp/cdp/inspector/events.py +41 -0
- parsek_cdp/cdp/inspector/functions.py +27 -0
- parsek_cdp/cdp/inspector/types.py +10 -0
- parsek_cdp/cdp/io/__init__.py +15 -0
- parsek_cdp/cdp/io/events.py +13 -0
- parsek_cdp/cdp/io/functions.py +77 -0
- parsek_cdp/cdp/io/types.py +13 -0
- parsek_cdp/cdp/layertree/__init__.py +15 -0
- parsek_cdp/cdp/layertree/events.py +36 -0
- parsek_cdp/cdp/layertree/functions.py +178 -0
- parsek_cdp/cdp/layertree/types.py +104 -0
- parsek_cdp/cdp/log/__init__.py +15 -0
- parsek_cdp/cdp/log/events.py +22 -0
- parsek_cdp/cdp/log/functions.py +54 -0
- parsek_cdp/cdp/log/types.py +57 -0
- parsek_cdp/cdp/media/__init__.py +15 -0
- parsek_cdp/cdp/media/events.py +87 -0
- parsek_cdp/cdp/media/functions.py +27 -0
- parsek_cdp/cdp/media/types.py +101 -0
- parsek_cdp/cdp/memory/__init__.py +15 -0
- parsek_cdp/cdp/memory/events.py +13 -0
- parsek_cdp/cdp/memory/functions.py +164 -0
- parsek_cdp/cdp/memory/types.py +71 -0
- parsek_cdp/cdp/mixins/__init__.py +21 -0
- parsek_cdp/cdp/mixins/datatype.py +123 -0
- parsek_cdp/cdp/mixins/event.py +78 -0
- parsek_cdp/cdp/mixins/namespace.py +31 -0
- parsek_cdp/cdp/network/__init__.py +15 -0
- parsek_cdp/cdp/network/events.py +726 -0
- parsek_cdp/cdp/network/functions.py +734 -0
- parsek_cdp/cdp/network/types.py +1247 -0
- parsek_cdp/cdp/overlay/__init__.py +15 -0
- parsek_cdp/cdp/overlay/events.py +54 -0
- parsek_cdp/cdp/overlay/functions.py +407 -0
- parsek_cdp/cdp/overlay/types.py +328 -0
- parsek_cdp/cdp/page/__init__.py +15 -0
- parsek_cdp/cdp/page/events.py +416 -0
- parsek_cdp/cdp/page/functions.py +1081 -0
- parsek_cdp/cdp/page/types.py +1088 -0
- parsek_cdp/cdp/performance/__init__.py +15 -0
- parsek_cdp/cdp/performance/events.py +24 -0
- parsek_cdp/cdp/performance/functions.py +63 -0
- parsek_cdp/cdp/performance/types.py +22 -0
- parsek_cdp/cdp/performancetimeline/__init__.py +15 -0
- parsek_cdp/cdp/performancetimeline/events.py +22 -0
- parsek_cdp/cdp/performancetimeline/functions.py +30 -0
- parsek_cdp/cdp/performancetimeline/types.py +85 -0
- parsek_cdp/cdp/preload/__init__.py +15 -0
- parsek_cdp/cdp/preload/events.py +116 -0
- parsek_cdp/cdp/preload/functions.py +25 -0
- parsek_cdp/cdp/preload/types.py +267 -0
- parsek_cdp/cdp/profiler/__init__.py +15 -0
- parsek_cdp/cdp/profiler/events.py +64 -0
- parsek_cdp/cdp/profiler/functions.py +134 -0
- parsek_cdp/cdp/profiler/types.py +105 -0
- parsek_cdp/cdp/pwa/__init__.py +15 -0
- parsek_cdp/cdp/pwa/events.py +13 -0
- parsek_cdp/cdp/pwa/functions.py +196 -0
- parsek_cdp/cdp/pwa/types.py +45 -0
- parsek_cdp/cdp/runtime/__init__.py +15 -0
- parsek_cdp/cdp/runtime/events.py +123 -0
- parsek_cdp/cdp/runtime/functions.py +552 -0
- parsek_cdp/cdp/runtime/types.py +319 -0
- parsek_cdp/cdp/schema/__init__.py +15 -0
- parsek_cdp/cdp/schema/events.py +13 -0
- parsek_cdp/cdp/schema/functions.py +32 -0
- parsek_cdp/cdp/schema/types.py +22 -0
- parsek_cdp/cdp/security/__init__.py +15 -0
- parsek_cdp/cdp/security/events.py +64 -0
- parsek_cdp/cdp/security/functions.py +66 -0
- parsek_cdp/cdp/security/types.py +168 -0
- parsek_cdp/cdp/serviceworker/__init__.py +15 -0
- parsek_cdp/cdp/serviceworker/events.py +43 -0
- parsek_cdp/cdp/serviceworker/functions.py +115 -0
- parsek_cdp/cdp/serviceworker/types.py +95 -0
- parsek_cdp/cdp/storage/__init__.py +15 -0
- parsek_cdp/cdp/storage/events.py +288 -0
- parsek_cdp/cdp/storage/functions.py +571 -0
- parsek_cdp/cdp/storage/types.py +656 -0
- parsek_cdp/cdp/systeminfo/__init__.py +15 -0
- parsek_cdp/cdp/systeminfo/events.py +13 -0
- parsek_cdp/cdp/systeminfo/functions.py +75 -0
- parsek_cdp/cdp/systeminfo/types.py +132 -0
- parsek_cdp/cdp/target/__init__.py +15 -0
- parsek_cdp/cdp/target/events.py +109 -0
- parsek_cdp/cdp/target/functions.py +424 -0
- parsek_cdp/cdp/target/types.py +83 -0
- parsek_cdp/cdp/tethering/__init__.py +15 -0
- parsek_cdp/cdp/tethering/events.py +22 -0
- parsek_cdp/cdp/tethering/functions.py +35 -0
- parsek_cdp/cdp/tethering/types.py +10 -0
- parsek_cdp/cdp/tracing/__init__.py +15 -0
- parsek_cdp/cdp/tracing/events.py +61 -0
- parsek_cdp/cdp/tracing/functions.py +119 -0
- parsek_cdp/cdp/tracing/types.py +81 -0
- parsek_cdp/cdp/webaudio/__init__.py +15 -0
- parsek_cdp/cdp/webaudio/events.py +184 -0
- parsek_cdp/cdp/webaudio/functions.py +51 -0
- parsek_cdp/cdp/webaudio/types.py +155 -0
- parsek_cdp/cdp/webauthn/__init__.py +15 -0
- parsek_cdp/cdp/webauthn/events.py +69 -0
- parsek_cdp/cdp/webauthn/functions.py +214 -0
- parsek_cdp/cdp/webauthn/types.py +96 -0
- parsek_cdp/core/__init__.py +18 -0
- parsek_cdp/core/browser.py +240 -0
- parsek_cdp/core/browser_context.py +58 -0
- parsek_cdp/core/element.py +405 -0
- parsek_cdp/core/feature.py +376 -0
- parsek_cdp/core/frame.py +351 -0
- parsek_cdp/core/pagable.py +175 -0
- parsek_cdp/core/page.py +163 -0
- parsek_cdp/core/target.py +490 -0
- parsek_cdp/features/__init__.py +14 -0
- parsek_cdp/features/request_listener/__init__.py +256 -0
- parsek_cdp/features/request_listener/events.py +48 -0
- parsek_cdp/features/request_listener/types.py +235 -0
- parsek_cdp/generate.py +642 -0
- parsek_cdp/parsek/__init__.py +18 -0
- parsek_cdp/parsek/events.py +38 -0
- parsek_cdp/parsek/types.py +36 -0
- parsek_cdp/py.typed +0 -0
- parsek_cdp-0.1.0.dist-info/METADATA +277 -0
- parsek_cdp-0.1.0.dist-info/RECORD +242 -0
- parsek_cdp-0.1.0.dist-info/WHEEL +5 -0
- parsek_cdp-0.1.0.dist-info/licenses/LICENSE +201 -0
- parsek_cdp-0.1.0.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,319 @@
|
|
|
1
|
+
"""Custom types and enums for the Runtime domain (generated)."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from enum import Enum
|
|
6
|
+
from typing import Any, ClassVar, Dict, List, Literal, Optional
|
|
7
|
+
|
|
8
|
+
from ..mixins.datatype import DataType, FieldMeta, register
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
type ScriptId = str # Unique script identifier.
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
@register("Runtime.SerializationOptions")
|
|
15
|
+
@dataclass
|
|
16
|
+
class SerializationOptions(DataType):
|
|
17
|
+
"""Represents options for serialization. Overrides `generatePreview` and `returnByValue`."""
|
|
18
|
+
serialization: Literal['deep', 'json', 'idOnly']
|
|
19
|
+
max_depth: Optional[int] = None
|
|
20
|
+
additional_parameters: Optional[Dict[str, Any]] = None
|
|
21
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
22
|
+
FieldMeta('serialization', 'serialization', False, 'primitive'),
|
|
23
|
+
FieldMeta('max_depth', 'maxDepth', True, 'primitive'),
|
|
24
|
+
FieldMeta('additional_parameters', 'additionalParameters', True, 'primitive'),
|
|
25
|
+
)
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
@register("Runtime.DeepSerializedValue")
|
|
29
|
+
@dataclass
|
|
30
|
+
class DeepSerializedValue(DataType):
|
|
31
|
+
"""Represents deep serialized value."""
|
|
32
|
+
type_: Literal['undefined', 'null', 'string', 'number', 'boolean', 'bigint', 'regexp', 'date', 'symbol', 'array', 'object', 'function', 'map', 'set', 'weakmap', 'weakset', 'error', 'proxy', 'promise', 'typedarray', 'arraybuffer', 'node', 'window', 'generator']
|
|
33
|
+
value: Optional[Any] = None
|
|
34
|
+
object_id: Optional[str] = None
|
|
35
|
+
weak_local_object_reference: Optional[int] = None
|
|
36
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
37
|
+
FieldMeta('type_', 'type', False, 'primitive'),
|
|
38
|
+
FieldMeta('value', 'value', True, 'primitive'),
|
|
39
|
+
FieldMeta('object_id', 'objectId', True, 'primitive'),
|
|
40
|
+
FieldMeta('weak_local_object_reference', 'weakLocalObjectReference', True, 'primitive'),
|
|
41
|
+
)
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
type RemoteObjectId = str # Unique object identifier.
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
type UnserializableValue = str # Primitive value which cannot be JSON-stringified. Includes values `-0`, `NaN`, `Infinity`,
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
@register("Runtime.RemoteObject")
|
|
51
|
+
@dataclass
|
|
52
|
+
class RemoteObject(DataType):
|
|
53
|
+
"""Mirror object referencing original JavaScript object."""
|
|
54
|
+
type_: Literal['object', 'function', 'undefined', 'string', 'number', 'boolean', 'symbol', 'bigint']
|
|
55
|
+
subtype: Optional[Literal['array', 'null', 'node', 'regexp', 'date', 'map', 'set', 'weakmap', 'weakset', 'iterator', 'generator', 'error', 'proxy', 'promise', 'typedarray', 'arraybuffer', 'dataview', 'webassemblymemory', 'wasmvalue', 'trustedtype']] = None
|
|
56
|
+
class_name: Optional[str] = None
|
|
57
|
+
value: Optional[Any] = None
|
|
58
|
+
unserializable_value: Optional[UnserializableValue] = None
|
|
59
|
+
description: Optional[str] = None
|
|
60
|
+
deep_serialized_value: Optional[DeepSerializedValue] = None
|
|
61
|
+
object_id: Optional[RemoteObjectId] = None
|
|
62
|
+
preview: Optional[ObjectPreview] = None
|
|
63
|
+
custom_preview: Optional[CustomPreview] = None
|
|
64
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
65
|
+
FieldMeta('type_', 'type', False, 'primitive'),
|
|
66
|
+
FieldMeta('subtype', 'subtype', True, 'primitive'),
|
|
67
|
+
FieldMeta('class_name', 'className', True, 'primitive'),
|
|
68
|
+
FieldMeta('value', 'value', True, 'primitive'),
|
|
69
|
+
FieldMeta('unserializable_value', 'unserializableValue', True, 'primitive'),
|
|
70
|
+
FieldMeta('description', 'description', True, 'primitive'),
|
|
71
|
+
FieldMeta('deep_serialized_value', 'deepSerializedValue', True, 'object', ref='Runtime.DeepSerializedValue'),
|
|
72
|
+
FieldMeta('object_id', 'objectId', True, 'primitive'),
|
|
73
|
+
FieldMeta('preview', 'preview', True, 'object', ref='Runtime.ObjectPreview'),
|
|
74
|
+
FieldMeta('custom_preview', 'customPreview', True, 'object', ref='Runtime.CustomPreview'),
|
|
75
|
+
)
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
@register("Runtime.CustomPreview")
|
|
79
|
+
@dataclass
|
|
80
|
+
class CustomPreview(DataType):
|
|
81
|
+
header: str
|
|
82
|
+
body_getter_id: Optional[RemoteObjectId] = None
|
|
83
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
84
|
+
FieldMeta('header', 'header', False, 'primitive'),
|
|
85
|
+
FieldMeta('body_getter_id', 'bodyGetterId', True, 'primitive'),
|
|
86
|
+
)
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
@register("Runtime.ObjectPreview")
|
|
90
|
+
@dataclass
|
|
91
|
+
class ObjectPreview(DataType):
|
|
92
|
+
"""Object containing abbreviated remote object value."""
|
|
93
|
+
type_: Literal['object', 'function', 'undefined', 'string', 'number', 'boolean', 'symbol', 'bigint']
|
|
94
|
+
overflow: bool
|
|
95
|
+
properties: List[PropertyPreview]
|
|
96
|
+
subtype: Optional[Literal['array', 'null', 'node', 'regexp', 'date', 'map', 'set', 'weakmap', 'weakset', 'iterator', 'generator', 'error', 'proxy', 'promise', 'typedarray', 'arraybuffer', 'dataview', 'webassemblymemory', 'wasmvalue', 'trustedtype']] = None
|
|
97
|
+
description: Optional[str] = None
|
|
98
|
+
entries: Optional[List[EntryPreview]] = None
|
|
99
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
100
|
+
FieldMeta('type_', 'type', False, 'primitive'),
|
|
101
|
+
FieldMeta('overflow', 'overflow', False, 'primitive'),
|
|
102
|
+
FieldMeta('properties', 'properties', False, 'array', inner=FieldMeta('', '', False, 'object', ref='Runtime.PropertyPreview')),
|
|
103
|
+
FieldMeta('subtype', 'subtype', True, 'primitive'),
|
|
104
|
+
FieldMeta('description', 'description', True, 'primitive'),
|
|
105
|
+
FieldMeta('entries', 'entries', True, 'array', inner=FieldMeta('', '', False, 'object', ref='Runtime.EntryPreview')),
|
|
106
|
+
)
|
|
107
|
+
|
|
108
|
+
|
|
109
|
+
@register("Runtime.PropertyPreview")
|
|
110
|
+
@dataclass
|
|
111
|
+
class PropertyPreview(DataType):
|
|
112
|
+
name: str
|
|
113
|
+
type_: Literal['object', 'function', 'undefined', 'string', 'number', 'boolean', 'symbol', 'accessor', 'bigint']
|
|
114
|
+
value: Optional[str] = None
|
|
115
|
+
value_preview: Optional[ObjectPreview] = None
|
|
116
|
+
subtype: Optional[Literal['array', 'null', 'node', 'regexp', 'date', 'map', 'set', 'weakmap', 'weakset', 'iterator', 'generator', 'error', 'proxy', 'promise', 'typedarray', 'arraybuffer', 'dataview', 'webassemblymemory', 'wasmvalue', 'trustedtype']] = None
|
|
117
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
118
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
119
|
+
FieldMeta('type_', 'type', False, 'primitive'),
|
|
120
|
+
FieldMeta('value', 'value', True, 'primitive'),
|
|
121
|
+
FieldMeta('value_preview', 'valuePreview', True, 'object', ref='Runtime.ObjectPreview'),
|
|
122
|
+
FieldMeta('subtype', 'subtype', True, 'primitive'),
|
|
123
|
+
)
|
|
124
|
+
|
|
125
|
+
|
|
126
|
+
@register("Runtime.EntryPreview")
|
|
127
|
+
@dataclass
|
|
128
|
+
class EntryPreview(DataType):
|
|
129
|
+
value: ObjectPreview
|
|
130
|
+
key: Optional[ObjectPreview] = None
|
|
131
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
132
|
+
FieldMeta('value', 'value', False, 'object', ref='Runtime.ObjectPreview'),
|
|
133
|
+
FieldMeta('key', 'key', True, 'object', ref='Runtime.ObjectPreview'),
|
|
134
|
+
)
|
|
135
|
+
|
|
136
|
+
|
|
137
|
+
@register("Runtime.PropertyDescriptor")
|
|
138
|
+
@dataclass
|
|
139
|
+
class PropertyDescriptor(DataType):
|
|
140
|
+
"""Object property descriptor."""
|
|
141
|
+
name: str
|
|
142
|
+
configurable: bool
|
|
143
|
+
enumerable: bool
|
|
144
|
+
value: Optional[RemoteObject] = None
|
|
145
|
+
writable: Optional[bool] = None
|
|
146
|
+
get: Optional[RemoteObject] = None
|
|
147
|
+
set: Optional[RemoteObject] = None
|
|
148
|
+
was_thrown: Optional[bool] = None
|
|
149
|
+
is_own: Optional[bool] = None
|
|
150
|
+
symbol: Optional[RemoteObject] = None
|
|
151
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
152
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
153
|
+
FieldMeta('configurable', 'configurable', False, 'primitive'),
|
|
154
|
+
FieldMeta('enumerable', 'enumerable', False, 'primitive'),
|
|
155
|
+
FieldMeta('value', 'value', True, 'object', ref='Runtime.RemoteObject'),
|
|
156
|
+
FieldMeta('writable', 'writable', True, 'primitive'),
|
|
157
|
+
FieldMeta('get', 'get', True, 'object', ref='Runtime.RemoteObject'),
|
|
158
|
+
FieldMeta('set', 'set', True, 'object', ref='Runtime.RemoteObject'),
|
|
159
|
+
FieldMeta('was_thrown', 'wasThrown', True, 'primitive'),
|
|
160
|
+
FieldMeta('is_own', 'isOwn', True, 'primitive'),
|
|
161
|
+
FieldMeta('symbol', 'symbol', True, 'object', ref='Runtime.RemoteObject'),
|
|
162
|
+
)
|
|
163
|
+
|
|
164
|
+
|
|
165
|
+
@register("Runtime.InternalPropertyDescriptor")
|
|
166
|
+
@dataclass
|
|
167
|
+
class InternalPropertyDescriptor(DataType):
|
|
168
|
+
"""Object internal property descriptor. This property isn't normally visible in JavaScript code."""
|
|
169
|
+
name: str
|
|
170
|
+
value: Optional[RemoteObject] = None
|
|
171
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
172
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
173
|
+
FieldMeta('value', 'value', True, 'object', ref='Runtime.RemoteObject'),
|
|
174
|
+
)
|
|
175
|
+
|
|
176
|
+
|
|
177
|
+
@register("Runtime.PrivatePropertyDescriptor")
|
|
178
|
+
@dataclass
|
|
179
|
+
class PrivatePropertyDescriptor(DataType):
|
|
180
|
+
"""Object private field descriptor."""
|
|
181
|
+
name: str
|
|
182
|
+
value: Optional[RemoteObject] = None
|
|
183
|
+
get: Optional[RemoteObject] = None
|
|
184
|
+
set: Optional[RemoteObject] = None
|
|
185
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
186
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
187
|
+
FieldMeta('value', 'value', True, 'object', ref='Runtime.RemoteObject'),
|
|
188
|
+
FieldMeta('get', 'get', True, 'object', ref='Runtime.RemoteObject'),
|
|
189
|
+
FieldMeta('set', 'set', True, 'object', ref='Runtime.RemoteObject'),
|
|
190
|
+
)
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
@register("Runtime.CallArgument")
|
|
194
|
+
@dataclass
|
|
195
|
+
class CallArgument(DataType):
|
|
196
|
+
"""
|
|
197
|
+
Represents function call argument. Either remote object id `objectId`, primitive `value`,
|
|
198
|
+
unserializable primitive value or neither of (for undefined) them should be specified.
|
|
199
|
+
"""
|
|
200
|
+
value: Optional[Any] = None
|
|
201
|
+
unserializable_value: Optional[UnserializableValue] = None
|
|
202
|
+
object_id: Optional[RemoteObjectId] = None
|
|
203
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
204
|
+
FieldMeta('value', 'value', True, 'primitive'),
|
|
205
|
+
FieldMeta('unserializable_value', 'unserializableValue', True, 'primitive'),
|
|
206
|
+
FieldMeta('object_id', 'objectId', True, 'primitive'),
|
|
207
|
+
)
|
|
208
|
+
|
|
209
|
+
|
|
210
|
+
type ExecutionContextId = int # Id of an execution context.
|
|
211
|
+
|
|
212
|
+
|
|
213
|
+
@register("Runtime.ExecutionContextDescription")
|
|
214
|
+
@dataclass
|
|
215
|
+
class ExecutionContextDescription(DataType):
|
|
216
|
+
"""Description of an isolated world."""
|
|
217
|
+
id: ExecutionContextId
|
|
218
|
+
origin: str
|
|
219
|
+
name: str
|
|
220
|
+
unique_id: str
|
|
221
|
+
aux_data: Optional[Dict[str, Any]] = None
|
|
222
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
223
|
+
FieldMeta('id', 'id', False, 'primitive'),
|
|
224
|
+
FieldMeta('origin', 'origin', False, 'primitive'),
|
|
225
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
226
|
+
FieldMeta('unique_id', 'uniqueId', False, 'primitive'),
|
|
227
|
+
FieldMeta('aux_data', 'auxData', True, 'primitive'),
|
|
228
|
+
)
|
|
229
|
+
|
|
230
|
+
|
|
231
|
+
@register("Runtime.ExceptionDetails")
|
|
232
|
+
@dataclass
|
|
233
|
+
class ExceptionDetails(DataType):
|
|
234
|
+
"""
|
|
235
|
+
Detailed information about exception (or error) that was thrown during script compilation or
|
|
236
|
+
execution.
|
|
237
|
+
"""
|
|
238
|
+
exception_id: int
|
|
239
|
+
text: str
|
|
240
|
+
line_number: int
|
|
241
|
+
column_number: int
|
|
242
|
+
script_id: Optional[ScriptId] = None
|
|
243
|
+
url: Optional[str] = None
|
|
244
|
+
stack_trace: Optional[StackTrace] = None
|
|
245
|
+
exception: Optional[RemoteObject] = None
|
|
246
|
+
execution_context_id: Optional[ExecutionContextId] = None
|
|
247
|
+
exception_meta_data: Optional[Dict[str, Any]] = None
|
|
248
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
249
|
+
FieldMeta('exception_id', 'exceptionId', False, 'primitive'),
|
|
250
|
+
FieldMeta('text', 'text', False, 'primitive'),
|
|
251
|
+
FieldMeta('line_number', 'lineNumber', False, 'primitive'),
|
|
252
|
+
FieldMeta('column_number', 'columnNumber', False, 'primitive'),
|
|
253
|
+
FieldMeta('script_id', 'scriptId', True, 'primitive'),
|
|
254
|
+
FieldMeta('url', 'url', True, 'primitive'),
|
|
255
|
+
FieldMeta('stack_trace', 'stackTrace', True, 'object', ref='Runtime.StackTrace'),
|
|
256
|
+
FieldMeta('exception', 'exception', True, 'object', ref='Runtime.RemoteObject'),
|
|
257
|
+
FieldMeta('execution_context_id', 'executionContextId', True, 'primitive'),
|
|
258
|
+
FieldMeta('exception_meta_data', 'exceptionMetaData', True, 'primitive'),
|
|
259
|
+
)
|
|
260
|
+
|
|
261
|
+
|
|
262
|
+
type Timestamp = float # Number of milliseconds since epoch.
|
|
263
|
+
|
|
264
|
+
|
|
265
|
+
type TimeDelta = float # Number of milliseconds.
|
|
266
|
+
|
|
267
|
+
|
|
268
|
+
@register("Runtime.CallFrame")
|
|
269
|
+
@dataclass
|
|
270
|
+
class CallFrame(DataType):
|
|
271
|
+
"""Stack entry for runtime errors and assertions."""
|
|
272
|
+
function_name: str
|
|
273
|
+
script_id: ScriptId
|
|
274
|
+
url: str
|
|
275
|
+
line_number: int
|
|
276
|
+
column_number: int
|
|
277
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
278
|
+
FieldMeta('function_name', 'functionName', False, 'primitive'),
|
|
279
|
+
FieldMeta('script_id', 'scriptId', False, 'primitive'),
|
|
280
|
+
FieldMeta('url', 'url', False, 'primitive'),
|
|
281
|
+
FieldMeta('line_number', 'lineNumber', False, 'primitive'),
|
|
282
|
+
FieldMeta('column_number', 'columnNumber', False, 'primitive'),
|
|
283
|
+
)
|
|
284
|
+
|
|
285
|
+
|
|
286
|
+
@register("Runtime.StackTrace")
|
|
287
|
+
@dataclass
|
|
288
|
+
class StackTrace(DataType):
|
|
289
|
+
"""Call frames for assertions or error messages."""
|
|
290
|
+
call_frames: List[CallFrame]
|
|
291
|
+
description: Optional[str] = None
|
|
292
|
+
parent: Optional[StackTrace] = None
|
|
293
|
+
parent_id: Optional[StackTraceId] = None
|
|
294
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
295
|
+
FieldMeta('call_frames', 'callFrames', False, 'array', inner=FieldMeta('', '', False, 'object', ref='Runtime.CallFrame')),
|
|
296
|
+
FieldMeta('description', 'description', True, 'primitive'),
|
|
297
|
+
FieldMeta('parent', 'parent', True, 'object', ref='Runtime.StackTrace'),
|
|
298
|
+
FieldMeta('parent_id', 'parentId', True, 'object', ref='Runtime.StackTraceId'),
|
|
299
|
+
)
|
|
300
|
+
|
|
301
|
+
|
|
302
|
+
type UniqueDebuggerId = str # Unique identifier of current debugger.
|
|
303
|
+
|
|
304
|
+
|
|
305
|
+
@register("Runtime.StackTraceId")
|
|
306
|
+
@dataclass
|
|
307
|
+
class StackTraceId(DataType):
|
|
308
|
+
"""
|
|
309
|
+
If `debuggerId` is set stack trace comes from another debugger and can be resolved there. This
|
|
310
|
+
allows to track cross-debugger calls. See `Runtime.StackTrace` and `Debugger.paused` for usages.
|
|
311
|
+
"""
|
|
312
|
+
id: str
|
|
313
|
+
debugger_id: Optional[UniqueDebuggerId] = None
|
|
314
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
315
|
+
FieldMeta('id', 'id', False, 'primitive'),
|
|
316
|
+
FieldMeta('debugger_id', 'debuggerId', True, 'primitive'),
|
|
317
|
+
)
|
|
318
|
+
|
|
319
|
+
__all__ = ["CallArgument", "CallFrame", "CustomPreview", "DeepSerializedValue", "EntryPreview", "ExceptionDetails", "ExecutionContextDescription", "ExecutionContextId", "InternalPropertyDescriptor", "ObjectPreview", "PrivatePropertyDescriptor", "PropertyDescriptor", "PropertyPreview", "RemoteObject", "RemoteObjectId", "ScriptId", "SerializationOptions", "StackTrace", "StackTraceId", "TimeDelta", "Timestamp", "UniqueDebuggerId", "UnserializableValue"]
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"""The Schema CDP domain (generated).
|
|
2
|
+
|
|
3
|
+
Importing ``Schema`` from ``parsek_cdp.cdp`` gives a namespace with this
|
|
4
|
+
domain's events and types as attributes (``Schema.SomeEvent`` /
|
|
5
|
+
``Schema.SomeType``); commands run on a target via ``page.cdp.Schema``.
|
|
6
|
+
"""
|
|
7
|
+
from . import events, functions, types
|
|
8
|
+
from .functions import Schema
|
|
9
|
+
from .events import * # noqa: F401,F403 -- expose events on the namespace
|
|
10
|
+
from .types import * # noqa: F401,F403 -- expose types on the namespace
|
|
11
|
+
|
|
12
|
+
#: Protocol domain name (used by features that declare ``domains=(Schema,)``).
|
|
13
|
+
DOMAIN = "Schema"
|
|
14
|
+
|
|
15
|
+
__all__ = ["events", "functions", "types", "Schema", "DOMAIN"]
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"""Events for the Schema domain (generated)."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from typing import Any, ClassVar, Dict, List, Literal, Optional
|
|
6
|
+
|
|
7
|
+
from ..mixins.datatype import FieldMeta
|
|
8
|
+
from ..mixins.event import Event, register_event
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
# This domain defines no events.
|
|
12
|
+
|
|
13
|
+
__all__ = []
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"""Commands for the Schema domain (generated)."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from typing import TYPE_CHECKING, Any, ClassVar, Dict, List, Literal, Optional
|
|
6
|
+
|
|
7
|
+
from ..mixins.datatype import DataType, FieldMeta, encode
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from .types import Domain
|
|
11
|
+
|
|
12
|
+
@dataclass
|
|
13
|
+
class GetDomainsReturn(DataType):
|
|
14
|
+
"""Return value of :meth:`Schema.get_domains`."""
|
|
15
|
+
domains: List[Domain]
|
|
16
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
17
|
+
FieldMeta('domains', 'domains', False, 'array', inner=FieldMeta('', '', False, 'object', ref='Schema.Domain')),
|
|
18
|
+
)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
class Schema:
|
|
22
|
+
"""Commands of the Schema domain, bound to a target."""
|
|
23
|
+
|
|
24
|
+
def __init__(self, target: Any) -> None:
|
|
25
|
+
self._target = target
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
async def get_domains(self) -> GetDomainsReturn:
|
|
29
|
+
"""Returns supported domains."""
|
|
30
|
+
_params: Dict[str, Any] = {}
|
|
31
|
+
_result = await self._target.send('Schema.getDomains', _params)
|
|
32
|
+
return GetDomainsReturn.from_json(_result)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"""Custom types and enums for the Schema domain (generated)."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from enum import Enum
|
|
6
|
+
from typing import Any, ClassVar, Dict, List, Literal, Optional
|
|
7
|
+
|
|
8
|
+
from ..mixins.datatype import DataType, FieldMeta, register
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
@register("Schema.Domain")
|
|
12
|
+
@dataclass
|
|
13
|
+
class Domain(DataType):
|
|
14
|
+
"""Description of the protocol domain."""
|
|
15
|
+
name: str
|
|
16
|
+
version: str
|
|
17
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
18
|
+
FieldMeta('name', 'name', False, 'primitive'),
|
|
19
|
+
FieldMeta('version', 'version', False, 'primitive'),
|
|
20
|
+
)
|
|
21
|
+
|
|
22
|
+
__all__ = ["Domain"]
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"""The Security CDP domain (generated).
|
|
2
|
+
|
|
3
|
+
Importing ``Security`` from ``parsek_cdp.cdp`` gives a namespace with this
|
|
4
|
+
domain's events and types as attributes (``Security.SomeEvent`` /
|
|
5
|
+
``Security.SomeType``); commands run on a target via ``page.cdp.Security``.
|
|
6
|
+
"""
|
|
7
|
+
from . import events, functions, types
|
|
8
|
+
from .functions import Security
|
|
9
|
+
from .events import * # noqa: F401,F403 -- expose events on the namespace
|
|
10
|
+
from .types import * # noqa: F401,F403 -- expose types on the namespace
|
|
11
|
+
|
|
12
|
+
#: Protocol domain name (used by features that declare ``domains=(Security,)``).
|
|
13
|
+
DOMAIN = "Security"
|
|
14
|
+
|
|
15
|
+
__all__ = ["events", "functions", "types", "Security", "DOMAIN"]
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
"""Events for the Security domain (generated)."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from typing import TYPE_CHECKING, Any, ClassVar, Dict, List, Literal, Optional
|
|
6
|
+
|
|
7
|
+
from ..mixins.datatype import FieldMeta
|
|
8
|
+
from ..mixins.event import Event, register_event
|
|
9
|
+
|
|
10
|
+
if TYPE_CHECKING:
|
|
11
|
+
from .types import (
|
|
12
|
+
InsecureContentStatus,
|
|
13
|
+
SecurityState,
|
|
14
|
+
SecurityStateExplanation,
|
|
15
|
+
VisibleSecurityState,
|
|
16
|
+
)
|
|
17
|
+
|
|
18
|
+
@register_event("Security.certificateError")
|
|
19
|
+
@dataclass
|
|
20
|
+
class CertificateError(Event):
|
|
21
|
+
"""
|
|
22
|
+
There is a certificate error. If overriding certificate errors is enabled, then it should be
|
|
23
|
+
handled with the `handleCertificateError` command. Note: this event does not fire if the
|
|
24
|
+
certificate error has been allowed internally. Only one client per target should override
|
|
25
|
+
certificate errors at the same time.
|
|
26
|
+
"""
|
|
27
|
+
event_id: int
|
|
28
|
+
error_type: str
|
|
29
|
+
request_url: str
|
|
30
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
31
|
+
FieldMeta('event_id', 'eventId', False, 'primitive'),
|
|
32
|
+
FieldMeta('error_type', 'errorType', False, 'primitive'),
|
|
33
|
+
FieldMeta('request_url', 'requestURL', False, 'primitive'),
|
|
34
|
+
)
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
@register_event("Security.visibleSecurityStateChanged")
|
|
38
|
+
@dataclass
|
|
39
|
+
class VisibleSecurityStateChanged(Event):
|
|
40
|
+
"""The security state of the page changed."""
|
|
41
|
+
visible_security_state: VisibleSecurityState
|
|
42
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
43
|
+
FieldMeta('visible_security_state', 'visibleSecurityState', False, 'object', ref='Security.VisibleSecurityState'),
|
|
44
|
+
)
|
|
45
|
+
|
|
46
|
+
|
|
47
|
+
@register_event("Security.securityStateChanged")
|
|
48
|
+
@dataclass
|
|
49
|
+
class SecurityStateChanged(Event):
|
|
50
|
+
"""The security state of the page changed. No longer being sent."""
|
|
51
|
+
security_state: SecurityState
|
|
52
|
+
scheme_is_cryptographic: bool
|
|
53
|
+
explanations: List[SecurityStateExplanation]
|
|
54
|
+
insecure_content_status: InsecureContentStatus
|
|
55
|
+
summary: Optional[str] = None
|
|
56
|
+
__FIELDS__: ClassVar[tuple] = (
|
|
57
|
+
FieldMeta('security_state', 'securityState', False, 'enum', ref='Security.SecurityState'),
|
|
58
|
+
FieldMeta('scheme_is_cryptographic', 'schemeIsCryptographic', False, 'primitive'),
|
|
59
|
+
FieldMeta('explanations', 'explanations', False, 'array', inner=FieldMeta('', '', False, 'object', ref='Security.SecurityStateExplanation')),
|
|
60
|
+
FieldMeta('insecure_content_status', 'insecureContentStatus', False, 'object', ref='Security.InsecureContentStatus'),
|
|
61
|
+
FieldMeta('summary', 'summary', True, 'primitive'),
|
|
62
|
+
)
|
|
63
|
+
|
|
64
|
+
__all__ = ["CertificateError", "SecurityStateChanged", "VisibleSecurityStateChanged"]
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
"""Commands for the Security domain (generated)."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
from dataclasses import dataclass
|
|
5
|
+
from typing import TYPE_CHECKING, Any, ClassVar, Dict, List, Literal, Optional
|
|
6
|
+
|
|
7
|
+
from ..mixins.datatype import DataType, FieldMeta, encode
|
|
8
|
+
|
|
9
|
+
if TYPE_CHECKING:
|
|
10
|
+
from .types import CertificateErrorAction
|
|
11
|
+
|
|
12
|
+
class Security:
|
|
13
|
+
"""Commands of the Security domain, bound to a target."""
|
|
14
|
+
|
|
15
|
+
def __init__(self, target: Any) -> None:
|
|
16
|
+
self._target = target
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
async def disable(self) -> None:
|
|
20
|
+
"""Disables tracking security state changes."""
|
|
21
|
+
_params: Dict[str, Any] = {}
|
|
22
|
+
_result = await self._target.send('Security.disable', _params)
|
|
23
|
+
return None
|
|
24
|
+
|
|
25
|
+
async def enable(self) -> None:
|
|
26
|
+
"""Enables tracking security state changes."""
|
|
27
|
+
_params: Dict[str, Any] = {}
|
|
28
|
+
_result = await self._target.send('Security.enable', _params)
|
|
29
|
+
return None
|
|
30
|
+
|
|
31
|
+
async def set_ignore_certificate_errors(self, *, ignore: bool) -> None:
|
|
32
|
+
"""
|
|
33
|
+
Enable/disable whether all certificate errors should be ignored.
|
|
34
|
+
:param ignore: If true, all certificate errors will be ignored.
|
|
35
|
+
"""
|
|
36
|
+
_params: Dict[str, Any] = {}
|
|
37
|
+
_params['ignore'] = encode(FieldMeta('', '', False, 'primitive'), ignore)
|
|
38
|
+
_result = await self._target.send('Security.setIgnoreCertificateErrors', _params)
|
|
39
|
+
return None
|
|
40
|
+
|
|
41
|
+
async def handle_certificate_error(self, *, event_id: int, action: CertificateErrorAction) -> None:
|
|
42
|
+
"""
|
|
43
|
+
Handles a certificate error that fired a certificateError event.
|
|
44
|
+
|
|
45
|
+
.. deprecated::
|
|
46
|
+
:param event_id: The ID of the event.
|
|
47
|
+
:param action: The action to take on the certificate error.
|
|
48
|
+
"""
|
|
49
|
+
_params: Dict[str, Any] = {}
|
|
50
|
+
_params['eventId'] = encode(FieldMeta('', '', False, 'primitive'), event_id)
|
|
51
|
+
_params['action'] = encode(FieldMeta('', '', False, 'enum', ref='Security.CertificateErrorAction'), action)
|
|
52
|
+
_result = await self._target.send('Security.handleCertificateError', _params)
|
|
53
|
+
return None
|
|
54
|
+
|
|
55
|
+
async def set_override_certificate_errors(self, *, override: bool) -> None:
|
|
56
|
+
"""
|
|
57
|
+
Enable/disable overriding certificate errors. If enabled, all certificate error events need to
|
|
58
|
+
be handled by the DevTools client and should be answered with `handleCertificateError` commands.
|
|
59
|
+
|
|
60
|
+
.. deprecated::
|
|
61
|
+
:param override: If true, certificate errors will be overridden.
|
|
62
|
+
"""
|
|
63
|
+
_params: Dict[str, Any] = {}
|
|
64
|
+
_params['override'] = encode(FieldMeta('', '', False, 'primitive'), override)
|
|
65
|
+
_result = await self._target.send('Security.setOverrideCertificateErrors', _params)
|
|
66
|
+
return None
|