Skip to content

Commit ca3fb84

Browse files
authored
Merge branch 'main' into ai-findings-autofix/tests-unit-test_plugin_logging.py
2 parents e3577a2 + 7d8d24d commit ca3fb84

3 files changed

Lines changed: 13 additions & 2 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ instance/
6767

6868
# Scrapy stuff:
6969
.scrapy
70+
.git
7071

7172
# Sphinx documentation
7273
docs/_build/

docs/conf.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,10 @@
1717
"myst_parser",
1818
]
1919

20+
# MyST is enabled for basic Markdown parsing only.
21+
# Keep advanced syntax extensions disabled unless explicitly needed.
22+
myst_enable_extensions = []
23+
2024
templates_path = ["_templates"]
2125
exclude_patterns = []
2226

tests/e2e/test_flaky_simulation.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,17 @@
44
Requires --reruns 1 (included in `make test`).
55
"""
66

7+
import threading
8+
79
attempt_counter = {"count": 0}
10+
attempt_lock = threading.Lock()
811

912

1013
def test_flaky_network_call():
11-
attempt_counter["count"] += 1
12-
if attempt_counter["count"] == 1:
14+
with attempt_lock:
15+
attempt_counter["count"] += 1
16+
is_first_attempt = attempt_counter["count"] == 1
17+
18+
if is_first_attempt:
1319
assert False, "Simulated network failure"
1420
assert True

0 commit comments

Comments
 (0)