@@ -48,10 +48,61 @@ def read_json(
4848 nrows : int | None = ...,
4949 storage_options : StorageOptions = ...,
5050 dtype_backend : DtypeBackend | NoDefault = ...,
51+ engine : Literal ["ujson" ] = ...,
5152) -> JsonReader [Series ]: ...
5253@overload
5354def read_json (
54- path_or_buf : FilePath | ReadBuffer [str ] | ReadBuffer [bytes ],
55+ path_or_buf : FilePath | ReadBuffer [bytes ],
56+ * ,
57+ orient : JsonSeriesOrient | None = ...,
58+ typ : Literal ["series" ],
59+ dtype : bool | Mapping [HashableT , DtypeArg ] | None = ...,
60+ convert_axes : bool | None = ...,
61+ convert_dates : bool | list [str ] = ...,
62+ keep_default_dates : bool = ...,
63+ precise_float : bool = ...,
64+ date_unit : TimeUnit | None = ...,
65+ encoding : str | None = ...,
66+ encoding_errors : (
67+ Literal ["strict" , "ignore" , "replace" , "backslashreplace" , "surrogateescape" ]
68+ | None
69+ ) = ...,
70+ lines : Literal [True ],
71+ chunksize : int ,
72+ compression : CompressionOptions = ...,
73+ nrows : int | None = ...,
74+ storage_options : StorageOptions = ...,
75+ dtype_backend : DtypeBackend | NoDefault = ...,
76+ engine : Literal ["pyarrow" ],
77+ ) -> JsonReader [Series ]: ...
78+ @overload
79+ def read_json (
80+ path_or_buf : FilePath | ReadBuffer [bytes ],
81+ * ,
82+ orient : JsonFrameOrient | None = ...,
83+ typ : Literal ["frame" ] = ...,
84+ dtype : bool | Mapping [HashableT , DtypeArg ] | None = ...,
85+ convert_axes : bool | None = ...,
86+ convert_dates : bool | list [str ] = ...,
87+ keep_default_dates : bool = ...,
88+ precise_float : bool = ...,
89+ date_unit : TimeUnit | None = ...,
90+ encoding : str | None = ...,
91+ encoding_errors : (
92+ Literal ["strict" , "ignore" , "replace" , "backslashreplace" , "surrogateescape" ]
93+ | None
94+ ) = ...,
95+ lines : Literal [True ],
96+ chunksize : int ,
97+ compression : CompressionOptions = ...,
98+ nrows : int | None = ...,
99+ storage_options : StorageOptions = ...,
100+ dtype_backend : DtypeBackend | NoDefault = ...,
101+ engine : Literal ["ujson" ] = ...,
102+ ) -> JsonReader [DataFrame ]: ...
103+ @overload
104+ def read_json (
105+ path_or_buf : FilePath | ReadBuffer [bytes ],
55106 * ,
56107 orient : JsonFrameOrient | None = ...,
57108 typ : Literal ["frame" ] = ...,
@@ -72,6 +123,7 @@ def read_json(
72123 nrows : int | None = ...,
73124 storage_options : StorageOptions = ...,
74125 dtype_backend : DtypeBackend | NoDefault = ...,
126+ engine : Literal ["pyarrow" ],
75127) -> JsonReader [DataFrame ]: ...
76128@overload
77129def read_json (
@@ -96,6 +148,32 @@ def read_json(
96148 nrows : int | None = ...,
97149 storage_options : StorageOptions = ...,
98150 dtype_backend : DtypeBackend | NoDefault = ...,
151+ engine : Literal ["ujson" ] = ...,
152+ ) -> Series : ...
153+ @overload
154+ def read_json (
155+ path_or_buf : FilePath | ReadBuffer [bytes ],
156+ * ,
157+ orient : JsonSeriesOrient | None = ...,
158+ typ : Literal ["series" ],
159+ dtype : bool | Mapping [HashableT , DtypeArg ] | None = ...,
160+ convert_axes : bool | None = ...,
161+ convert_dates : bool | list [str ] = ...,
162+ keep_default_dates : bool = ...,
163+ precise_float : bool = ...,
164+ date_unit : TimeUnit | None = ...,
165+ encoding : str | None = ...,
166+ encoding_errors : (
167+ Literal ["strict" , "ignore" , "replace" , "backslashreplace" , "surrogateescape" ]
168+ | None
169+ ) = ...,
170+ lines : Literal [True ],
171+ chunksize : None = ...,
172+ compression : CompressionOptions = ...,
173+ nrows : int | None = ...,
174+ storage_options : StorageOptions = ...,
175+ dtype_backend : DtypeBackend | NoDefault = ...,
176+ engine : Literal ["pyarrow" ],
99177) -> Series : ...
100178@overload
101179def read_json (
@@ -120,6 +198,32 @@ def read_json(
120198 nrows : int | None = ...,
121199 storage_options : StorageOptions = ...,
122200 dtype_backend : DtypeBackend | NoDefault = ...,
201+ engine : Literal ["ujson" ] = ...,
202+ ) -> DataFrame : ...
203+ @overload
204+ def read_json (
205+ path_or_buf : FilePath | ReadBuffer [bytes ],
206+ * ,
207+ orient : JsonFrameOrient | None = ...,
208+ typ : Literal ["frame" ] = ...,
209+ dtype : bool | Mapping [HashableT , DtypeArg ] | None = ...,
210+ convert_axes : bool | None = ...,
211+ convert_dates : bool | list [str ] = ...,
212+ keep_default_dates : bool = ...,
213+ precise_float : bool = ...,
214+ date_unit : TimeUnit | None = ...,
215+ encoding : str | None = ...,
216+ encoding_errors : (
217+ Literal ["strict" , "ignore" , "replace" , "backslashreplace" , "surrogateescape" ]
218+ | None
219+ ) = ...,
220+ lines : Literal [True ],
221+ chunksize : None = ...,
222+ compression : CompressionOptions = ...,
223+ nrows : int | None = ...,
224+ storage_options : StorageOptions = ...,
225+ dtype_backend : DtypeBackend | NoDefault = ...,
226+ engine : Literal ["pyarrow" ],
123227) -> DataFrame : ...
124228
125229class JsonReader (abc .Iterator , Generic [NDFrameT ]):
0 commit comments