File tree Expand file tree Collapse file tree 3 files changed +12
-2
lines changed Expand file tree Collapse file tree 3 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,10 @@ repos:
2323 rev : v1.17.1
2424 hooks :
2525 - id : mypy
26+ # Match all files under duckdb/ or _duckdb-stubs/,
27+ # but not under duckdb/experimental/ or duckdb/query_graph/
28+ files : ^(duckdb/(?!experimental/|query_graph/)|_duckdb-stubs/)
29+ args : ["--config-file", "pyproject.toml"]
2630
2731 - repo : local
2832 hooks :
Original file line number Diff line number Diff line change @@ -277,8 +277,8 @@ def source_generator(
277277 for record_batch in iter (results .read_next_batch , None ):
278278 if predicate is not None and duck_predicate is None :
279279 # We have a predicate, but did not manage to push it down, we fallback here
280- yield pl .from_arrow (record_batch ).filter (predicate ) # type: ignore[arg-type,misc]
280+ yield pl .from_arrow (record_batch ).filter (predicate ) # type: ignore[arg-type,misc,unused-ignore ]
281281 else :
282- yield pl .from_arrow (record_batch ) # type: ignore[misc]
282+ yield pl .from_arrow (record_batch ) # type: ignore[misc,unused-ignore ]
283283
284284 return register_io_source (source_generator , schema = schema )
Original file line number Diff line number Diff line change @@ -316,20 +316,26 @@ filterwarnings = [
316316
317317[tool .mypy ]
318318packages = [" duckdb" , " _duckdb" ]
319+ mypy_path = [" _duckdb-stubs" ]
319320strict = true
320321warn_unreachable = true
321322pretty = true
322323python_version = " 3.9"
323324exclude = [
324325 " duckdb/experimental/" , # not checking the pyspark API
325326 " duckdb/query_graph/" , # old and unmaintained (should probably remove)
327+ " tests" ,
328+ " scripts" ,
329+ " sqlogic" ,
326330]
327331
328332[[tool .mypy .overrides ]]
329333module = [
330334 " fsspec.*" ,
335+ " numpy" ,
331336 " pandas" ,
332337 " polars" ,
338+ " polars.io.plugins" ,
333339 " pyarrow.*" ,
334340 " torch" ,
335341 " tensorflow" ,
You can’t perform that action at this time.
0 commit comments