File tree 7 files changed +5
-238
lines changed
7 files changed +5
-238
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ assignees: ''
10
10
** Context:**
11
11
- Playwright Version: [ what Playwright version do you use?]
12
12
- Operating System: [ e.g. Windows, Linux or Mac]
13
- - Python version: [ e.g. 3.7 , 3.9]
13
+ - Python version: [ e.g. 3.8 , 3.9]
14
14
- Browser: [ e.g. All, Chromium, Firefox, WebKit]
15
15
- Extra: [ any specific details about your environment]
16
16
Original file line number Diff line number Diff line change @@ -43,34 +43,13 @@ jobs:
43
43
build :
44
44
name : Build
45
45
timeout-minutes : 45
46
- env :
47
- DEBUG : pw:*
48
- DEBUG_FILE : pw-log.txt
49
46
strategy :
50
47
fail-fast : false
51
48
matrix :
52
49
os : [ubuntu-latest, windows-latest, macos-latest]
53
- python-version : [3.7 , 3.8 ]
50
+ python-version : [3.8 , 3.9 ]
54
51
browser : [chromium, firefox, webkit]
55
52
include :
56
- - os : ubuntu-latest
57
- python-version : 3.9
58
- browser : chromium
59
- - os : windows-latest
60
- python-version : 3.9
61
- browser : chromium
62
- - os : macos-latest
63
- python-version : 3.9
64
- browser : chromium
65
- - os : macos-11.0
66
- python-version : 3.9
67
- browser : chromium
68
- - os : macos-11.0
69
- python-version : 3.9
70
- browser : firefox
71
- - os : macos-11.0
72
- python-version : 3.9
73
- browser : webkit
74
53
- os : ubuntu-latest
75
54
python-version : ' 3.10'
76
55
browser : chromium
@@ -129,18 +108,10 @@ jobs:
129
108
- name : Test Async API
130
109
if : matrix.os == 'ubuntu-latest'
131
110
run : xvfb-run pytest tests/async --browser=${{ matrix.browser }} --timeout 90
132
- - uses : actions/upload-artifact@v3
133
- if : failure()
134
- with :
135
- name : ${{ matrix.browser }}-${{ matrix.os }}-${{ matrix.python-version }}
136
- path : pw-log.txt
137
111
138
112
test-stable :
139
113
name : Stable
140
114
timeout-minutes : 45
141
- env :
142
- DEBUG : pw:*
143
- DEBUG_FILE : pw-log.txt
144
115
strategy :
145
116
fail-fast : false
146
117
matrix :
@@ -179,11 +150,6 @@ jobs:
179
150
- name : Test Async API
180
151
if : matrix.os == 'ubuntu-latest'
181
152
run : xvfb-run pytest tests/async --browser=chromium --browser-channel=${{ matrix.browser-channel }} --timeout 90
182
- - uses : actions/upload-artifact@v3
183
- if : failure()
184
- with :
185
- name : ${{ matrix.browser-channel }}-${{ matrix.os }}
186
- path : pw-log.txt
187
153
188
154
build-conda :
189
155
name : Conda Build
Original file line number Diff line number Diff line change 12
12
# See the License for the specific language governing permissions and
13
13
# limitations under the License.
14
14
15
- import asyncio
16
15
import inspect
17
16
import os
18
17
import sys
@@ -30,22 +29,6 @@ def compute_driver_executable() -> Path:
30
29
return package_path / "driver" / "playwright.sh"
31
30
32
31
33
- if sys .version_info .major == 3 and sys .version_info .minor == 7 :
34
- if sys .platform == "win32" :
35
- # Use ProactorEventLoop in 3.7, which is default in 3.8
36
- asyncio .set_event_loop_policy (asyncio .WindowsProactorEventLoopPolicy ())
37
- else :
38
- # Prevent Python 3.7 from throwing on Linux:
39
- # RuntimeError: Cannot add child handler, the child watcher does not have a loop attached
40
- asyncio .get_event_loop ()
41
- try :
42
- asyncio .get_child_watcher ()
43
- except Exception :
44
- # uvloop does not support child watcher
45
- # see https://github.com/microsoft/playwright-python/issues/582
46
- pass
47
-
48
-
49
32
def get_driver_env () -> dict :
50
33
env = os .environ .copy ()
51
34
env ["PW_LANG_NAME" ] = "python"
Original file line number Diff line number Diff line change 13
13
# limitations under the License.
14
14
15
15
import asyncio
16
- import sys
17
16
from typing import TYPE_CHECKING , Any , Optional , cast
18
17
19
18
from greenlet import greenlet
@@ -50,20 +49,6 @@ def __enter__(self) -> SyncPlaywright:
50
49
Please use the Async API instead."""
51
50
)
52
51
53
- # In Python 3.7, asyncio.Process.wait() hangs because it does not use ThreadedChildWatcher
54
- # which is used in Python 3.8+. This is unix specific and also takes care about
55
- # cleaning up zombie processes. See https://bugs.python.org/issue35621
56
- if (
57
- sys .version_info [0 ] == 3
58
- and sys .version_info [1 ] == 7
59
- and sys .platform != "win32"
60
- and isinstance (asyncio .get_child_watcher (), asyncio .SafeChildWatcher )
61
- ):
62
- from ._py37ThreadedChildWatcher import ThreadedChildWatcher # type: ignore
63
-
64
- self ._watcher = ThreadedChildWatcher ()
65
- asyncio .set_child_watcher (self ._watcher ) # type: ignore
66
-
67
52
# Create a new fiber for the protocol dispatcher. It will be pumping events
68
53
# until the end of times. We will pass control to that fiber every time we
69
54
# block while waiting for a response.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ asyncio_mode = "auto"
15
15
16
16
[tool .mypy ]
17
17
ignore_missing_imports = true
18
- python_version = " 3.7 "
18
+ python_version = " 3.8 "
19
19
warn_unused_ignores = false
20
20
warn_redundant_casts = true
21
21
warn_unused_configs = true
@@ -32,7 +32,7 @@ profile = "black"
32
32
[tool .pyright ]
33
33
include = [" playwright" , " tests/sync" ]
34
34
ignore = [" tests/async/" , " scripts/" , " examples/" ]
35
- pythonVersion = " 3.7 "
35
+ pythonVersion = " 3.8 "
36
36
reportMissingImports = false
37
37
reportTypedDictNotRequiredAccess = false
38
38
reportCallInDefaultInitializer = true
Original file line number Diff line number Diff line change @@ -221,15 +221,14 @@ def _download_and_extract_local_driver(
221
221
"Topic :: Internet :: WWW/HTTP :: Browsers" ,
222
222
"Intended Audience :: Developers" ,
223
223
"Programming Language :: Python :: 3" ,
224
- "Programming Language :: Python :: 3.7" ,
225
224
"Programming Language :: Python :: 3.8" ,
226
225
"Programming Language :: Python :: 3.9" ,
227
226
"Programming Language :: Python :: 3.10" ,
228
227
"Programming Language :: Python :: 3.11" ,
229
228
"License :: OSI Approved :: Apache Software License" ,
230
229
"Operating System :: OS Independent" ,
231
230
],
232
- python_requires = ">=3.7 " ,
231
+ python_requires = ">=3.8 " ,
233
232
cmdclass = {"bdist_wheel" : PlaywrightBDistWheelCommand },
234
233
use_scm_version = {
235
234
"version_scheme" : "post-release" ,
You can’t perform that action at this time.
0 commit comments