Skip to content

Commit cb0e899

Browse files
authored
Merge pull request #1886 from seleniumbase/fix-issue-with-long-filenames-in-logs
Fix issue with long filenames in logs
2 parents fda7a28 + 361ea71 commit cb0e899

File tree

7 files changed

+35
-25
lines changed

7 files changed

+35
-25
lines changed

examples/migration/protractor/mat_paginator_test.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,17 @@ def test_pagination(self):
1111
# Verify navigation to the next page
1212
self.click('button[aria-label="Next page"]')
1313
self.assert_exact_text(
14-
"Page 2 of 10", ".mat-mdc-paginator-range-label"
14+
"6 – 10 of 50", ".mat-mdc-paginator-range-label"
1515
)
1616
# Verify navigation to the previous page
1717
self.click('button[aria-label="Previous page"]')
1818
self.assert_exact_text(
19-
"Page 1 of 10", ".mat-mdc-paginator-range-label"
19+
"1 – 5 of 50", ".mat-mdc-paginator-range-label"
2020
)
2121
# Set pagination to 10 items per page
2222
self.click("mat-select > div")
2323
self.click("#mat-option-1")
2424
# Verify page with correct number of pages
25-
self.assert_exact_text("Page 1 of 5", ".mat-mdc-paginator-range-label")
25+
self.assert_exact_text(
26+
"1 – 10 of 50", ".mat-mdc-paginator-range-label"
27+
)

examples/wordle_test.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,7 @@ def test_wordle(self):
5454
self.open_if_not_url("about:blank")
5555
self.skip("Skip this test in headless mode!")
5656
self.open("https://www.nytimes.com/games/wordle/index.html")
57+
self.click_if_visible('button:contains("Play")', timeout=2)
5758
self.click_if_visible('svg[data-testid="icon-close"]', timeout=2)
5859
self.remove_elements("div.place-ad")
5960
self.initialize_word_list()

mkdocs_build/requirements.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
regex>=2023.5.5
55
pkginfo>=1.9.6
6-
docutils==0.20
6+
docutils==0.20.1
77
python-dateutil==2.8.2
88
livereload==2.6.3
99
joblib==1.2.0
@@ -13,21 +13,21 @@ Jinja2==3.1.2
1313
click==8.1.3
1414
ghp-import==2.1.0
1515
readme-renderer==37.3
16-
pymdown-extensions==9.11
16+
pymdown-extensions==10.0.1
1717
importlib-metadata==6.6.0
1818
pipdeptree==2.7.1
1919
bleach==6.0.0
2020
lunr==0.6.2
2121
nltk==3.8.1
22-
tornado==6.3.1
22+
tornado==6.3.2
2323
watchdog==3.0.0
2424
cairocffi==1.5.1
2525
cairosvg==2.7.0
2626
cssselect2==0.7.0
2727
tinycss2==1.2.1
2828
defusedxml==0.7.1
2929
mkdocs==1.4.3
30-
mkdocs-material==9.1.12
30+
mkdocs-material==9.1.14
3131
mkdocs-exclude-search==0.6.5
3232
mkdocs-simple-hooks==0.1.5
3333
mkdocs-material-extensions==1.1.1

requirements.txt

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ pip>=23.1.2;python_version>="3.7"
33
packaging>=21.3;python_version<"3.7"
44
packaging>=23.1;python_version>="3.7"
55
setuptools>=59.6.0;python_version<"3.7"
6-
setuptools>=67.7.2;python_version>="3.7"
6+
setuptools>=67.8.0;python_version>="3.7"
77
keyring>=23.4.1;python_version<"3.8"
88
keyring>=23.13.1;python_version>="3.8"
99
tomli>=1.2.3;python_version<"3.7"
@@ -35,9 +35,9 @@ charset-normalizer==3.1.0;python_version>="3.7"
3535
urllib3==1.26.12;python_version<"3.7"
3636
urllib3>=1.26.15,<2.1.0;python_version>="3.7"
3737
requests==2.27.1;python_version<"3.7"
38-
requests>=2.29.0,<2.31.0;python_version>="3.7"
38+
requests==2.31.0;python_version>="3.7"
3939
requests-toolbelt==1.0.0
40-
pynose==1.4.4
40+
pynose==1.4.5
4141
sniffio==1.3.0;python_version>="3.7"
4242
h11==0.14.0;python_version>="3.7"
4343
outcome==1.2.0;python_version>="3.7"
@@ -69,7 +69,7 @@ pytest-ordering==0.6
6969
pytest-rerunfailures==10.3;python_version<"3.7"
7070
pytest-rerunfailures==11.1.2;python_version>="3.7"
7171
pytest-xdist==2.5.0;python_version<"3.7"
72-
pytest-xdist==3.2.1;python_version>="3.7"
72+
pytest-xdist==3.3.1;python_version>="3.7"
7373
parameterized==0.8.1;python_version<"3.7"
7474
parameterized==0.9.0;python_version>="3.7"
7575
sbvirtualdisplay==1.2.0
@@ -105,8 +105,9 @@ rich==13.3.5;python_version>="3.7"
105105
# ("pip install -r requirements.txt" also installs this, but "pip install -e ." won't.)
106106

107107
coverage==6.2;python_version<"3.7"
108-
coverage==7.2.5;python_version>="3.7"
109-
pytest-cov==4.0.0
108+
coverage==7.2.6;python_version>="3.7"
109+
pytest-cov==4.0.0;python_version<"3.7"
110+
pytest-cov==4.1.0;python_version>="3.7"
110111
flake8==5.0.4;python_version<"3.9"
111112
flake8==6.0.0;python_version>="3.9"
112113
mccabe==0.7.0

seleniumbase/__version__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
# seleniumbase package
2-
__version__ = "4.14.9"
2+
__version__ = "4.14.10"

seleniumbase/fixtures/base_case.py

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14217,13 +14217,18 @@ def __get_test_id(self):
1421714217
)
1421814218
if self._sb_test_identifier and len(str(self._sb_test_identifier)) > 6:
1421914219
test_id = self._sb_test_identifier
14220-
test_id = test_id.replace(".py::", ".").replace("::", ".")
14221-
test_id = test_id.replace("/", ".").replace(" ", "_")
1422214220
elif hasattr(self, "_using_sb_fixture") and self._using_sb_fixture:
1422314221
test_id = sb_config._latest_display_id
14224-
test_id = test_id.replace(".py::", ".").replace("::", ".")
14225-
test_id = test_id.replace("/", ".").replace(" ", "_")
14226-
return test_id
14222+
test_id = test_id.replace(".py::", ".").replace("::", ".")
14223+
test_id = test_id.replace("/", ".").replace(" ", "_")
14224+
# Linux filename length limit for `codecs.open(filename)` = 255
14225+
# 255 - len("latest_logs/") - len("/basic_test_info.txt") = 223
14226+
if len(test_id) <= 223:
14227+
return test_id
14228+
else:
14229+
# 223 - len("__TRUNCATED__") = 210
14230+
# 210 / 2 = 105
14231+
return test_id[:105] + "__TRUNCATED__" + test_id[-105:]
1422714232

1422814233
def __get_test_id_2(self):
1422914234
"""The id for SeleniumBase Dashboard entries."""

setup.py

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,7 @@
127127
'packaging>=21.3;python_version<"3.7"',
128128
'packaging>=23.1;python_version>="3.7"',
129129
'setuptools>=59.6.0;python_version<"3.7"',
130-
'setuptools>=67.7.2;python_version>="3.7"',
130+
'setuptools>=67.8.0;python_version>="3.7"',
131131
'keyring>=23.4.1;python_version<"3.8"',
132132
'keyring>=23.13.1;python_version>="3.8"',
133133
'tomli>=1.2.3;python_version<"3.7"',
@@ -159,9 +159,9 @@
159159
'urllib3==1.26.12;python_version<"3.7"',
160160
'urllib3>=1.26.15,<2.1.0;python_version>="3.7"',
161161
'requests==2.27.1;python_version<"3.7"',
162-
'requests>=2.29.0,<2.31.0;python_version>="3.7"',
162+
'requests==2.31.0;python_version>="3.7"',
163163
'requests-toolbelt==1.0.0',
164-
"pynose==1.4.4",
164+
"pynose==1.4.5",
165165
'sniffio==1.3.0;python_version>="3.7"',
166166
'h11==0.14.0;python_version>="3.7"',
167167
'outcome==1.2.0;python_version>="3.7"',
@@ -193,7 +193,7 @@
193193
'pytest-rerunfailures==10.3;python_version<"3.7"',
194194
'pytest-rerunfailures==11.1.2;python_version>="3.7"',
195195
'pytest-xdist==2.5.0;python_version<"3.7"',
196-
'pytest-xdist==3.2.1;python_version>="3.7"',
196+
'pytest-xdist==3.3.1;python_version>="3.7"',
197197
'parameterized==0.8.1;python_version<"3.7"',
198198
'parameterized==0.9.0;python_version>="3.7"',
199199
"sbvirtualdisplay==1.2.0",
@@ -241,8 +241,9 @@
241241
# Usage: coverage run -m pytest; coverage html; coverage report
242242
"coverage": [
243243
'coverage==6.2;python_version<"3.7"',
244-
'coverage==7.2.5;python_version>="3.7"',
245-
"pytest-cov==4.0.0",
244+
'coverage==7.2.6;python_version>="3.7"',
245+
'pytest-cov==4.0.0;python_version<"3.7"',
246+
'pytest-cov==4.1.0;python_version>="3.7"',
246247
],
247248
# pip install -e .[flake8]
248249
# Usage: flake8

0 commit comments

Comments
 (0)