Skip to content

Commit bca79d8

Browse files
fix: pin chardet<6 to suppress RequestsDependencyWarning (#405)
requests 2.32.5 asserts chardet<6 at import time, but sqlfluff and diff_cover pull in chardet without an upper bound, resolving to 7.1.0 on fresh installs. Add a workspace constraint to cap chardet until a new requests release ships the fix from psf/requests#7220. Closes #404
1 parent b94b88b commit bca79d8

2 files changed

Lines changed: 1075 additions & 1004 deletions

File tree

pyproject.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ members = [
3131
# IMPORTANT: This root is NOT a package. It only defines workspace configuration.
3232
package = false
3333
required-version = ">=0.7.10"
34+
# Pin chardet<6 to avoid RequestsDependencyWarning from requests<2.33
35+
# (requests checks chardet<6 at import time). See: https://github.com/psf/requests/issues/7219
36+
constraint-dependencies = ["chardet>=3.0.2,<6"]
3437

3538
[dependency-groups]
3639
dev = [

0 commit comments

Comments
 (0)