@@ -636,7 +636,7 @@ def read_csv(
636
636
comment : str | None = ...,
637
637
encoding : str | None = ...,
638
638
encoding_errors : str | None = ...,
639
- dialect = ...,
639
+ dialect : str | csv . Dialect | None = ...,
640
640
error_bad_lines : bool | None = ...,
641
641
warn_bad_lines : bool | None = ...,
642
642
on_bad_lines = ...,
@@ -696,7 +696,7 @@ def read_csv(
696
696
comment : str | None = ...,
697
697
encoding : str | None = ...,
698
698
encoding_errors : str | None = ...,
699
- dialect = ...,
699
+ dialect : str | csv . Dialect | None = ...,
700
700
error_bad_lines : bool | None = ...,
701
701
warn_bad_lines : bool | None = ...,
702
702
on_bad_lines = ...,
@@ -756,7 +756,7 @@ def read_csv(
756
756
comment : str | None = ...,
757
757
encoding : str | None = ...,
758
758
encoding_errors : str | None = ...,
759
- dialect = ...,
759
+ dialect : str | csv . Dialect | None = ...,
760
760
error_bad_lines : bool | None = ...,
761
761
warn_bad_lines : bool | None = ...,
762
762
on_bad_lines = ...,
@@ -816,7 +816,7 @@ def read_csv(
816
816
comment : str | None = ...,
817
817
encoding : str | None = ...,
818
818
encoding_errors : str | None = ...,
819
- dialect = ...,
819
+ dialect : str | csv . Dialect | None = ...,
820
820
error_bad_lines : bool | None = ...,
821
821
warn_bad_lines : bool | None = ...,
822
822
on_bad_lines = ...,
@@ -891,7 +891,7 @@ def read_csv(
891
891
comment : str | None = None ,
892
892
encoding : str | None = None ,
893
893
encoding_errors : str | None = "strict" ,
894
- dialect = None ,
894
+ dialect : str | csv . Dialect | None = None ,
895
895
# Error Handling
896
896
error_bad_lines : bool | None = None ,
897
897
warn_bad_lines : bool | None = None ,
@@ -975,7 +975,7 @@ def read_table(
975
975
comment : str | None = ...,
976
976
encoding : str | None = ...,
977
977
encoding_errors : str | None = ...,
978
- dialect = ...,
978
+ dialect : str | csv . Dialect | None = ...,
979
979
error_bad_lines : bool | None = ...,
980
980
warn_bad_lines : bool | None = ...,
981
981
on_bad_lines = ...,
@@ -1035,7 +1035,7 @@ def read_table(
1035
1035
comment : str | None = ...,
1036
1036
encoding : str | None = ...,
1037
1037
encoding_errors : str | None = ...,
1038
- dialect = ...,
1038
+ dialect : str | csv . Dialect | None = ...,
1039
1039
error_bad_lines : bool | None = ...,
1040
1040
warn_bad_lines : bool | None = ...,
1041
1041
on_bad_lines = ...,
@@ -1095,7 +1095,7 @@ def read_table(
1095
1095
comment : str | None = ...,
1096
1096
encoding : str | None = ...,
1097
1097
encoding_errors : str | None = ...,
1098
- dialect = ...,
1098
+ dialect : str | csv . Dialect | None = ...,
1099
1099
error_bad_lines : bool | None = ...,
1100
1100
warn_bad_lines : bool | None = ...,
1101
1101
on_bad_lines = ...,
@@ -1155,7 +1155,7 @@ def read_table(
1155
1155
comment : str | None = ...,
1156
1156
encoding : str | None = ...,
1157
1157
encoding_errors : str | None = ...,
1158
- dialect = ...,
1158
+ dialect : str | csv . Dialect | None = ...,
1159
1159
error_bad_lines : bool | None = ...,
1160
1160
warn_bad_lines : bool | None = ...,
1161
1161
on_bad_lines = ...,
@@ -1230,7 +1230,7 @@ def read_table(
1230
1230
comment : str | None = None ,
1231
1231
encoding : str | None = None ,
1232
1232
encoding_errors : str | None = "strict" ,
1233
- dialect = None ,
1233
+ dialect : str | csv . Dialect | None = None ,
1234
1234
# Error Handling
1235
1235
error_bad_lines : bool | None = None ,
1236
1236
warn_bad_lines : bool | None = None ,
@@ -1702,10 +1702,7 @@ def _make_engine(
1702
1702
if engine == "pyarrow" :
1703
1703
is_text = False
1704
1704
mode = "rb"
1705
- # error: No overload variant of "get_handle" matches argument types
1706
- # "Union[str, PathLike[str], ReadCsvBuffer[bytes], ReadCsvBuffer[str]]"
1707
- # , "str", "bool", "Any", "Any", "Any", "Any", "Any"
1708
- self .handles = get_handle ( # type: ignore[call-overload]
1705
+ self .handles = get_handle (
1709
1706
f ,
1710
1707
mode ,
1711
1708
encoding = self .options .get ("encoding" , None ),
@@ -1925,7 +1922,7 @@ def _stringify_na_values(na_values):
1925
1922
1926
1923
1927
1924
def _refine_defaults_read (
1928
- dialect : str | csv .Dialect ,
1925
+ dialect : str | csv .Dialect | None ,
1929
1926
delimiter : str | None | lib .NoDefault ,
1930
1927
delim_whitespace : bool ,
1931
1928
engine : CSVEngine | None ,
0 commit comments