Skip to content

Commit 712b033

Browse files
committed
chore: add ruff settings to pyproject.toml
Add ruff settings to pyproject.toml to prevent deprecation warnings beyond our control and to disable formatting for now to avoid the noise it would generate.
1 parent f8da894 commit 712b033

File tree

1 file changed

+21
-0
lines changed

1 file changed

+21
-0
lines changed

Diff for: pyproject.toml

+21
Original file line numberDiff line numberDiff line change
@@ -96,3 +96,24 @@ crawl4ai = { workspace = true }
9696
dev = [
9797
"crawl4ai",
9898
]
99+
100+
[tool.pytest.ini_options]
101+
asyncio_default_fixture_loop_scope = "function" # Prevent deprecation warning
102+
# Disable deprecation warnings for code we don't control.
103+
filterwarnings = [
104+
"ignore::DeprecationWarning",
105+
"default::DeprecationWarning:__main__",
106+
"default::DeprecationWarning:crawl4ai.*",
107+
]
108+
timeout = 20
109+
timeout_func_only = true
110+
111+
# Basic configuration for the `ruff` tool to preserve basic formatting.
112+
[tool.ruff]
113+
line-length = 120
114+
target-version = "py39"
115+
116+
# As a temporary workaround, exclude all files from ruff formatting as the
117+
# code base has various code style and would introduce a lot of noise.
118+
[tool.ruff.format]
119+
exclude = ["*.py"]

0 commit comments

Comments
 (0)