Repository: pandas-dev/pandas-stubs (language: python)

Issue:
Version 2.0 Compatibility Tracker
This is the list of things that are in pandas 2.0 release notes that need to be addressed in pandas-stubs.  PR's welcome.  If you do a PR, check off the item and put a link to the PR that closed it.  One PR can address multiple issues.

Some of these may already have been taken care of, so if so, check them off and indicate with a comment such as "previously complete"

- [x] Int64Index, UInt64Index & Float64Index were deprecated in pandas version 1.4 and have now been removed. Instead [Index](https://pandas.pydata.org/docs/reference/api/pandas.Index.html#pandas.Index) should be used directly, and can it now take all numpy numeric dtypes, i.e. int8/ int16/int32/int64/uint8/uint16/uint32/uint64/float32/float64 dtypes:  #626
- [x] The various numeric datetime attributes of [DatetimeIndex](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.html#pandas.DatetimeIndex) ([day](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.day.html#pandas.DatetimeIndex.day), [month](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.month.html#pandas.DatetimeIndex.month), [year](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.year.html#pandas.DatetimeIndex.year) etc.) were previously in of dtype int64, while they were int32 for [arrays.DatetimeArray](https://pandas.pydata.org/docs/reference/api/pandas.arrays.DatetimeArray.html#pandas.arrays.DatetimeArray). They are now int32 on [DatetimeIndex](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.html#pandas.DatetimeIndex) also  #632
- [x] Level dtypes on Indexes from [Series.sparse.from_coo()](https://pandas.pydata.org/docs/reference/api/pandas.Series.sparse.from_coo.html#pandas.Series.sparse.from_coo) are now of dtype int32, the same as they are on the rows/cols on a scipy sparse matrix. Previously they were of dtype int64  #632
- [x] [Index](https://pandas.pydata.org/docs/reference/api/pandas.Index.html#pandas.Index) cannot be instantiated using a float16 dtype. Previously instantiating an [Index](https://pandas.pydata.org/docs/reference/api/pandas.Index.html#pandas.Index) using dtype float16 resulted in a Float64Index with a float64 dtype.  #632
- [x] The following functions gained a new keyword dtype_backend ([GH36712](https://github.com/pandas-dev/pandas/issues/36712)) #655
  - [x] [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv)
  - [x] [read_clipboard()](https://pandas.pydata.org/docs/reference/api/pandas.read_clipboard.html#pandas.read_clipboard)
  - [x] [read_fwf()](https://pandas.pydata.org/docs/reference/api/pandas.read_fwf.html#pandas.read_fwf)
  - [x] [read_excel()](https://pandas.pydata.org/docs/reference/api/pandas.read_excel.html#pandas.read_excel)
  - [x] [read_html()](https://pandas.pydata.org/docs/reference/api/pandas.read_html.html#pandas.read_html)
  - [x] [read_xml()](https://pandas.pydata.org/docs/reference/api/pandas.read_xml.html#pandas.read_xml)
  - [x] [read_json()](https://pandas.pydata.org/docs/reference/api/pandas.read_json.html#pandas.read_json) 
  - [x] [read_sql()](https://pandas.pydata.org/docs/reference/api/pandas.read_sql.html#pandas.read_sql) #649
  - [x] [read_sql_query()](https://pandas.pydata.org/docs/reference/api/pandas.read_sql_query.html#pandas.read_sql_query)
  - [x] [read_sql_table()](https://pandas.pydata.org/docs/reference/api/pandas.read_sql_table.html#pandas.read_sql_table)
  - [x] [read_orc()](https://pandas.pydata.org/docs/reference/api/pandas.read_orc.html#pandas.read_orc)
  - [x] [read_feather()](https://pandas.pydata.org/docs/reference/api/pandas.read_feather.html#pandas.read_feather)
  - [x] [read_spss()](https://pandas.pydata.org/docs/reference/api/pandas.read_spss.html#pandas.read_spss)
  - [x] [to_numeric()](https://pandas.pydata.org/docs/reference/api/pandas.to_numeric.html#pandas.to_numeric)
  - [x] [DataFrame.convert_dtypes()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.convert_dtypes.html#pandas.DataFrame.convert_dtypes)
  - [x] [Series.convert_dtypes()](https://pandas.pydata.org/docs/reference/api/pandas.Series.convert_dtypes.html#pandas.Series.convert_dtypes)
- [ ] Copy-on-Write can be enabled through one of
  - [ ] pd.set_option("mode.copy_on_write", True)
  - [ ] pd.options.mode.copy_on_write = True
  - [ ] with pd.option_context("mode.copy_on_write", True):
- [x] ~~Added support for str accessor methods when using [ArrowDtype](https://pandas.pydata.org/docs/reference/api/pandas.ArrowDtype.html#pandas.ArrowDtype) with a pyarrow.string type~~
- [x] ~~Added support for dt accessor methods when using [ArrowDtype](https://pandas.pydata.org/docs/reference/api/pandas.ArrowDtype.html#pandas.ArrowDtype) with a pyarrow.timestamp type~~
- [x] ~~[read_sas()](https://pandas.pydata.org/docs/reference/api/pandas.read_sas.html#pandas.read_sas) now supports using encoding='infer' to correctly read and use the encoding specified by the sas file.~~
- [x] [Series.add_suffix()](https://pandas.pydata.org/docs/reference/api/pandas.Series.add_suffix.html#pandas.Series.add_suffix), [DataFrame.add_suffix()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.add_suffix.html#pandas.DataFrame.add_suffix), [Series.add_prefix()](https://pandas.pydata.org/docs/reference/api/pandas.Series.add_prefix.html#pandas.Series.add_prefix) and [DataFrame.add_prefix()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.add_prefix.html#pandas.DataFrame.add_prefix) support an axis argument. #638
- [x] Added index parameter to [DataFrame.to_dict()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_dict.html#pandas.DataFrame.to_dict)  #638
- [ ] Added cumsum, cumprod, cummin and cummax to the ExtensionArray interface via _accumulate
- [ ] [CategoricalConversionWarning](https://pandas.pydata.org/docs/reference/api/pandas.errors.CategoricalConversionWarning.html#pandas.errors.CategoricalConversionWarning), [InvalidComparison](https://pandas.pydata.org/docs/reference/api/pandas.errors.InvalidComparison.html#pandas.errors.InvalidComparison), [InvalidVersion](https://pandas.pydata.org/docs/reference/api/pandas.errors.InvalidVersion.html#pandas.errors.InvalidVersion), [LossySetitemError](https://pandas.pydata.org/docs/reference/api/pandas.errors.LossySetitemError.html#pandas.errors.LossySetitemError), and [NoBufferPresent](https://pandas.pydata.org/docs/reference/api/pandas.errors.NoBufferPresent.html#pandas.errors.NoBufferPresent) are now exposed in pandas.errors
- [x] [date_range()](https://pandas.pydata.org/docs/reference/api/pandas.date_range.html#pandas.date_range) now supports a unit keyword (“s”, “ms”, “us”, or “ns”) to specify the desired resolution of the output index  #734
- [x] [DataFrame.to_json()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_json.html#pandas.DataFrame.to_json) now supports a mode keyword with supported inputs ‘w’ and ‘a’. Defaulting to ‘w’, ‘a’ can be used when lines=True and orient=’records’ to append record oriented json lines to an existing json file. #684
- [x] ~~Added name parameter to [IntervalIndex.from_breaks()](https://pandas.pydata.org/docs/reference/api/pandas.IntervalIndex.from_breaks.html#pandas.IntervalIndex.from_breaks), [IntervalIndex.from_arrays()](https://pandas.pydata.org/docs/reference/api/pandas.IntervalIndex.from_arrays.html#pandas.IntervalIndex.from_arrays) and [IntervalIndex.from_tuples()](https://pandas.pydata.org/docs/reference/api/pandas.IntervalIndex.from_tuples.html#pandas.IntervalIndex.from_tuples)~~
- [ ] Added [Index.infer_objects()](https://pandas.pydata.org/docs/reference/api/pandas.Index.infer_objects.html#pandas.Index.infer_objects) analogous to [Series.infer_objects()](https://pandas.pydata.org/docs/reference/api/pandas.Series.infer_objects.html#pandas.Series.infer_objects)
- [ ] [DataFrame.plot.hist()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.plot.hist.html#pandas.DataFrame.plot.hist) now recognizes xlabel and ylabel arguments
- [x] [Series.drop_duplicates()](https://pandas.pydata.org/docs/reference/api/pandas.Series.drop_duplicates.html#pandas.Series.drop_duplicates) has gained ignore_index keyword to reset index  #1030
- [x] [Series.dropna()](https://pandas.pydata.org/docs/reference/api/pandas.Series.dropna.html#pandas.Series.dropna) and [DataFrame.dropna()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.dropna.html#pandas.DataFrame.dropna) has gained ignore_index keyword to reset index #1030
- [ ] Added [DatetimeIndex.as_unit()](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.as_unit.html#pandas.DatetimeIndex.as_unit) and [TimedeltaIndex.as_unit()](https://pandas.pydata.org/docs/reference/api/pandas.TimedeltaIndex.as_unit.html#pandas.TimedeltaIndex.as_unit) to convert to different resolutions; supported resolutions are “s”, “ms”, “us”, and “ns”
- [ ] Added [Series.dt.unit()](https://pandas.pydata.org/docs/reference/api/pandas.Series.dt.unit.html#pandas.Series.dt.unit) and [Series.dt.as_unit()](https://pandas.pydata.org/docs/reference/api/pandas.Series.dt.as_unit.html#pandas.Series.dt.as_unit) to convert to different resolutions; supported resolutions are “s”, “ms”, “us”, and “ns”
- [x] Added new argument dtype to [read_sql()](https://pandas.pydata.org/docs/reference/api/pandas.read_sql.html#pandas.read_sql) to be consistent with [read_sql_query()](https://pandas.pydata.org/docs/reference/api/pandas.read_sql_query.html#pandas.read_sql_query)  #649
- [x] [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv)  now accept date_format #650
- [x] [read_table()](https://pandas.pydata.org/docs/reference/api/pandas.read_table.html#pandas.read_table), [read_fwf()](https://pandas.pydata.org/docs/reference/api/pandas.read_fwf.html#pandas.read_fwf) and [read_excel()](https://pandas.pydata.org/docs/reference/api/pandas.read_excel.html#pandas.read_excel) now accept date_format #695
- [ ] [to_datetime()](https://pandas.pydata.org/docs/reference/api/pandas.to_datetime.html#pandas.to_datetime) now accepts "ISO8601" as an argument to format, which will match any ISO8601 string (but possibly not identically-formatted)
- [ ] [to_datetime()](https://pandas.pydata.org/docs/reference/api/pandas.to_datetime.html#pandas.to_datetime) now accepts "mixed" as an argument to format, which will infer the format for each element individually
- [x] Added new argument engine to [read_json()](https://pandas.pydata.org/docs/reference/api/pandas.read_json.html#pandas.read_json) to support parsing JSON with pyarrow by specifying engine="pyarrow" #1033
- [ ] Added support for decimal parameter when engine="pyarrow" in [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv)
- [ ] [Index](https://pandas.pydata.org/docs/reference/api/pandas.Index.html#pandas.Index) set operations [Index.union()](https://pandas.pydata.org/docs/reference/api/pandas.Index.union.html#pandas.Index.union), [Index.intersection()](https://pandas.pydata.org/docs/reference/api/pandas.Index.intersection.html#pandas.Index.intersection), [Index.difference()](https://pandas.pydata.org/docs/reference/api/pandas.Index.difference.html#pandas.Index.difference), and [Index.symmetric_difference()](https://pandas.pydata.org/docs/reference/api/pandas.Index.symmetric_difference.html#pandas.Index.symmetric_difference) now support sort=True, which will always return a sorted result, unlike the default sort=None which does not sort in some cases
- [ ] Construction with datetime64 or timedelta64 dtype with unsupported resolution (check allowable resolutions for `pd.Series()`)
- [ ] Disallow astype conversion to non-supported datetime64/timedelta64 dtypes
- [ ] The pandas latex options below are no longer used and have been removed. The generic max rows and columns arguments remain but for this functionality should be replaced by the Styler equivalents. The alternative options giving similar functionality are indicated below:
  - [ ] display.latex.escape: replaced with styler.format.escape,
  - [ ] display.latex.longtable: replaced with styler.latex.environment,
  - [ ] display.latex.multicolumn, display.latex.multicolumn_format and display.latex.multirow: replaced with styler.sparse.rows, styler.sparse.columns, styler.latex.multirow_align and styler.latex.multicol_align,
  - [ ] display.latex.repr: replaced with styler.render.repr,
  - [ ] display.max_rows and display.max_columns: replace with styler.render.max_rows, styler.render.max_columns and styler.render.max_elements.
  - [ ] The freq, tz, nanosecond, and unit keywords in the [Timestamp](https://pandas.pydata.org/docs/reference/api/pandas.Timestamp.html#pandas.Timestamp) constructor are now keyword-only
- [ ] Default value of dtype in [get_dummies()](https://pandas.pydata.org/docs/reference/api/pandas.get_dummies.html#pandas.get_dummies) is changed to bool from uint8
- [ ] DatetimeIndex.astype(), TimedeltaIndex.astype(), PeriodIndex.astype() [Series.astype()](https://pandas.pydata.org/docs/reference/api/pandas.Series.astype.html#pandas.Series.astype), [DataFrame.astype()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.astype.html#pandas.DataFrame.astype) with datetime64, timedelta64 or [PeriodDtype](https://pandas.pydata.org/docs/reference/api/pandas.PeriodDtype.html#pandas.PeriodDtype) dtypes no longer allow converting to integer dtypes other than “int64”, do obj.astype('int64', copy=False).astype(dtype) instead
- [x] The other argument in [DataFrame.mask()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.mask.html#pandas.DataFrame.mask) and [Series.mask()](https://pandas.pydata.org/docs/reference/api/pandas.Series.mask.html#pandas.Series.mask) now defaults to no_default instead of np.nan consistent with [DataFrame.where()] (https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.where.html#pandas.DataFrame.where) and [Series.where()](https://pandas.pydata.org/docs/reference/api/pandas.Series.where.html#pandas.Series.where). #1065
- [x] [Series.unique()](https://pandas.pydata.org/docs/reference/api/pandas.Series.unique.html#pandas.Series.unique) with dtype “timedelta64[ns]” or “datetime64[ns]” now returns TimedeltaArray or DatetimeArray instead of numpy.ndarray #1039
- [ ] [to_datetime()](https://pandas.pydata.org/docs/reference/api/pandas.to_datetime.html#pandas.to_datetime) and [DatetimeIndex](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.html#pandas.DatetimeIndex) now allow sequences containing both datetime objects and numeric entries, matching [Series](https://pandas.pydata.org/docs/reference/api/pandas.Series.html#pandas.Series) behavior
- [X] ~~Added "None" to default na_values in [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv)~~ #715
- [ ] Disallow computing cumprod for [Timedelta](https://pandas.pydata.org/docs/reference/api/pandas.Timedelta.html#pandas.Timedelta) object; previously this returned incorrect values
- [ ] The levels of the index of the [Series](https://pandas.pydata.org/docs/reference/api/pandas.Series.html#pandas.Series) returned from Series.sparse.from_coo now always have dtype int32. Previously they had dtype int64
- [x] Added [pandas.api.types.is_any_real_numeric_dtype()](https://pandas.pydata.org/docs/reference/api/pandas.api.types.is_any_real_numeric_dtype.html#pandas.api.types.is_any_real_numeric_dtype) to check for real numeric dtypes   #715
- [x] Deprecated argument infer_datetime_format in [to_datetime()](https://pandas.pydata.org/docs/reference/api/pandas.to_datetime.html#pandas.to_datetime) and [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv), as a strict version of it is now the default #1063
- [x] Deprecated pandas.io.sql.execute() #1063
- [x] [Index.is_boolean()](https://pandas.pydata.org/docs/reference/api/pandas.Index.is_boolean.html#pandas.Index.is_boolean) has been deprecated #1050
- [x] [Index.is_integer()](https://pandas.pydata.org/docs/reference/api/pandas.Index.is_integer.html#pandas.Index.is_integer) has been deprecated. #1050
- [x] [Index.is_floating()](https://pandas.pydata.org/docs/reference/api/pandas.Index.is_floating.html#pandas.Index.is_floating) has been deprecated. #1050
- [x] [Index.holds_integer()](https://pandas.pydata.org/docs/reference/api/pandas.Index.holds_integer.html#pandas.Index.holds_integer) has been deprecated. #1050
- [x] [Index.is_numeric()](https://pandas.pydata.org/docs/reference/api/pandas.Index.is_numeric.html#pandas.Index.is_numeric) has been deprecated. #1050
- [x] [Index.is_categorical()](https://pandas.pydata.org/docs/reference/api/pandas.Index.is_categorical.html#pandas.Index.is_categorical) has been deprecated. #1050
- [x] [Index.is_object()](https://pandas.pydata.org/docs/reference/api/pandas.Index.is_object.html#pandas.Index.is_object) has been deprecated. #1050
- [x] [Index.is_interval()](https://pandas.pydata.org/docs/reference/api/pandas.Index.is_interval.html#pandas.Index.is_interval) has been deprecated. #1050
- [x] Deprecated argument date_parser in [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv), [read_table()](https://pandas.pydata.org/docs/reference/api/pandas.read_table.html#pandas.read_table), [read_fwf()](https://pandas.pydata.org/docs/reference/api/pandas.read_fwf.html#pandas.read_fwf), and [read_excel()](https://pandas.pydata.org/docs/reference/api/pandas.read_excel.html#pandas.read_excel) in favour of date_format #695
- [X] Deprecated unused arguments *args and **kwargs in Resampler  #1063
- [x] Deprecated Grouper.groups() #1050
- [x] ~~Deprecated Grouper.grouper()~~
- [x] ~~Deprecated Grouper.obj()~~
- [x] ~~Deprecated Grouper.indexer()~~
- [x] ~~Deprecated Grouper.ax()~~
- [x] Deprecated keyword use_nullable_dtypes in [read_parquet()]  (https://pandas.pydata.org/docs/reference/api/pandas.read_parquet.html#pandas.read_parquet) #1050
- [X] ~~Deprecated [Series.pad()](https://pandas.pydata.org/docs/reference/api/pandas.Series.pad.html#pandas.Series.pad)~~
- [X] ~~Deprecated [Series.backfill()](https://pandas.pydata.org/docs/reference/api/pandas.Series.backfill.html#pandas.Series.backfill)~~
- [X] ~~Deprecated [DataFrame.pad()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.pad.html#pandas.DataFrame.pad)~~
- [X] ~~Deprecated [DataFrame.backfill()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.backfill.html#pandas.DataFrame.backfill)~~
- [X] Deprecated close(). Use StataReader as a context manager instead #1063
- [x] ~~Removed Int64Index, UInt64Index and Float64Index.~~
- [x] Removed deprecated Timestamp.freq, Timestamp.freqstr and argument freq from the [Timestamp](https://pandas.pydata.org/docs/reference/api/pandas.Timestamp.html#pandas.Timestamp) constructor and [Timestamp.fromordinal()] #1065
- [ ] (https://pandas.pydata.org/docs/reference/api/pandas.Timestamp.fromordinal.html#pandas.Timestamp.fromordinal)
- [ ] Removed deprecated CategoricalBlock, Block.is_categorical(), require datetime64 and timedelta64 values to be wrapped in DatetimeArray or TimedeltaArray before passing to Block.make_block_same_class(), require DatetimeTZBlock.values to have the correct ndim when passing to the BlockManager constructor, and removed the “fastpath” keyword from the SingleBlockManager constructor 
- [ ] Removed deprecated global option use_inf_as_null in favor of use_inf_as_na
- [ ] Removed deprecated module pandas.core.index
- [x] ~~Removed deprecated alias pandas.core.tools.datetimes.to_time~~
- [ ] Removed deprecated alias pandas.io.json.json_normalize
- [x] Removed deprecated Categorical.to_dense() (#932)
- [x] Removed deprecated Categorical.take_nd()  (#931) (#932)
- [x] Removed deprecated Categorical.mode()  (#932)
- [x] Removed deprecated Categorical.is_dtype_equal() and CategoricalIndex.is_dtype_equal()  (#932)
- [x] Removed deprecated CategoricalIndex.take_nd() (#931)
- [x] Removed deprecated Index.is_type_compatible()  (#931)
- [x] Removed deprecated Index.is_mixed() (#931)
- [ ] Removed deprecated pandas.api.types.is_categorical()
- [x] Removed deprecated Index.asi8()  (#931)
- [ ] Removed deprecated DataFrame._AXIS_NUMBERS(), DataFrame._AXIS_NAMES(), Series._AXIS_NUMBERS(), Series._AXIS_NAMES()
- [x] Removed deprecated Index.to_native_types()  (#931)
- [ ] Removed deprecated Series.iteritems(), DataFrame.iteritems()
- [x] Removed deprecated DataFrame.lookup() (#930)
- [ ] Removed deprecated Series.append(), DataFrame.append()
- [ ] Removed deprecated Series.iteritems(), DataFrame.iteritems() and HDFStore.iteritems()
- [ ] Removed deprecated DatetimeIndex.union_many()
- [ ] Removed deprecated weekofyear and week attributes of DatetimeArray, [DatetimeIndex](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.html#pandas.DatetimeIndex) and dt accessor  (#932)
- [ ] Removed deprecated RangeIndex._start(), RangeIndex._stop(), RangeIndex._step()
- [x] Removed deprecated DatetimeIndex.to_perioddelta()  (#931)
- [ ] Removed deprecated Styler.hide_index() and Styler.hide_columns()
- [ ] Removed deprecated Styler.set_na_rep() and Styler.set_precision()
- [ ] Removed deprecated Styler.where()
- [ ] Removed deprecated Styler.render()
- [x] Removed deprecated argument col_space in [DataFrame.to_latex()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_latex.html#pandas.DataFrame.to_latex) (#930)
- [ ] Removed deprecated argument null_color in [Styler.highlight_null()](https://pandas.pydata.org/docs/reference/api/pandas.io.formats.style.Styler.highlight_null.html#pandas.io.formats.style.Styler.highlight_null)
- [x] Removed deprecated argument check_less_precise in testing.assert_frame_equal(), testing.assert_extension_array_equal(), testing.assert_series_equal(), testing.assert_index_equal()  (#933)
- [ ] Removed deprecated null_counts argument in [DataFrame.info()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.info.html#pandas.DataFrame.info)
- [ ] Removed deprecated Index.is_monotonic(), and Series.is_monotonic()
- [x] Removed deprecated Index.is_all_dates()  (#931)
- [ ] Enforced deprecation disallowing unit-less “datetime64” dtype in [Series.astype()](https://pandas.pydata.org/docs/reference/api/pandas.Series.astype.html#pandas.Series.astype) and [DataFrame.astype()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.astype.html#pandas.DataFrame.astype)
- [ ] Enforced deprecation disallowing passing non boolean argument to sort in [concat()](https://pandas.pydata.org/docs/reference/api/pandas.concat.html#pandas.concat)
- [x] ~~Removed Date parser functions parse_date_time(), parse_date_fields(), parse_all_fields() and generic_parser()~~
- [ ] Removed argument index from the core.arrays.SparseArray constructor 
- [ ] Remove argument squeeze from [DataFrame.groupby()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.groupby.html#pandas.DataFrame.groupby) and [Series.groupby()](https://pandas.pydata.org/docs/reference/api/pandas.Series.groupby.html#pandas.Series.groupby)
- [ ] Removed deprecated apply, apply_index, __call__, onOffset, and isAnchored attributes from DateOffset
- [x] Removed keep_tz argument in [DatetimeIndex.to_series()](https://pandas.pydata.org/docs/reference/api/pandas.DatetimeIndex.to_series.html#pandas.DatetimeIndex.to_series) #802 
- [ ] Remove arguments names and dtype from [Index.copy()](https://pandas.pydata.org/docs/reference/api/pandas.Index.copy.html#pandas.Index.copy) and levels and codes from [MultiIndex.copy()](https://pandas.pydata.org/docs/reference/api/pandas.MultiIndex.copy.html#pandas.MultiIndex.copy)
- [ ] Remove argument inplace from [MultiIndex.set_levels()](https://pandas.pydata.org/docs/reference/api/pandas.MultiIndex.set_levels.html#pandas.MultiIndex.set_levels) and [MultiIndex.set_codes()](https://pandas.pydata.org/docs/reference/api/pandas.MultiIndex.set_codes.html#pandas.MultiIndex.set_codes)
- [ ] Removed arguments verbose and encoding from [DataFrame.to_excel()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_excel.html#pandas.DataFrame.to_excel) and [Series.to_excel()](https://pandas.pydata.org/docs/reference/api/pandas.Series.to_excel.html#pandas.Series.to_excel)
- [ ] Removed argument line_terminator from [DataFrame.to_csv()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_csv.html#pandas.DataFrame.to_csv) and [Series.to_csv()](https://pandas.pydata.org/docs/reference/api/pandas.Series.to_csv.html#pandas.Series.to_csv),
- [ ] Removed argument inplace from [DataFrame.set_axis()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.set_axis.html#pandas.DataFrame.set_axis) and [Series.set_axis()](https://pandas.pydata.org/docs/reference/api/pandas.Series.set_axis.html#pandas.Series.set_axis)
- [ ] Disallow passing positional arguments to [MultiIndex.set_levels()](https://pandas.pydata.org/docs/reference/api/pandas.MultiIndex.set_levels.html#pandas.MultiIndex.set_levels) and [MultiIndex.set_codes()](https://pandas.pydata.org/docs/reference/api/pandas.MultiIndex.set_codes.html#pandas.MultiIndex.set_codes)
- [ ] Disallow parsing to Timedelta strings with components with units “Y”, “y”, or “M”, as these do not represent unambiguous durations
- [ ] Removed MultiIndex.is_lexsorted() and MultiIndex.lexsort_depth()
- [ ] Removed argument how from PeriodIndex.astype()
- [x] Removed argument try_cast from [DataFrame.mask()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.mask.html#pandas.DataFrame.mask), [DataFrame.where()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.where.html#pandas.DataFrame.where), [Series.mask()](https://pandas.pydata.org/docs/reference/api/pandas.Series.mask.html#pandas.Series.mask) and [Series.where()](https://pandas.pydata.org/docs/reference/api/pandas.Series.where.html#pandas.Series.where)   (#930)
- [ ] Removed argument tz from [Period.to_timestamp()](https://pandas.pydata.org/docs/reference/api/pandas.Period.to_timestamp.html#pandas.Period.to_timestamp)
- [x] ~~Removed argument sort_columns in [DataFrame.plot()]~~(https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.plot.html#pandas.DataFrame.plot) and [Series.plot()](https://pandas.pydata.org/docs/reference/api/pandas.Series.plot.html#pandas.Series.plot)
- [x] Removed argument is_copy from [DataFrame.take()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.take.html#pandas.DataFrame.take) and [Series.take()](https://pandas.pydata.org/docs/reference/api/pandas.Series.take.html#pandas.Series.take)  (#930)
- [ ] Removed argument kind from [Index.get_slice_bound()](https://pandas.pydata.org/docs/reference/api/pandas.Index.get_slice_bound.html#pandas.Index.get_slice_bound), [Index.slice_indexer()](https://pandas.pydata.org/docs/reference/api/pandas.Index.slice_indexer.html#pandas.Index.slice_indexer) and [Index.slice_locs()](https://pandas.pydata.org/docs/reference/api/pandas.Index.slice_locs.html#pandas.Index.slice_locs)
- [ ] Removed arguments prefix, squeeze, error_bad_lines and warn_bad_lines from [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv)
- [x] ~~Removed arguments squeeze from [read_excel()]~~(https://pandas.pydata.org/docs/reference/api/pandas.read_excel.html#pandas.read_excel)
- [x] Removed argument datetime_is_numeric from [DataFrame.describe()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.describe.html#pandas.DataFrame.describe) and [Series.describe()](https://pandas.pydata.org/docs/reference/api/pandas.Series.describe.html#pandas.Series.describe) (#930)
- [ ] Disallow passing list key to [Series.xs()](https://pandas.pydata.org/docs/reference/api/pandas.Series.xs.html#pandas.Series.xs) and [DataFrame.xs()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.xs.html#pandas.DataFrame.xs)
- [ ] Disallow subclass-specific keywords (e.g. “freq”, “tz”, “names”, “closed”) in the [Index](https://pandas.pydata.org/docs/reference/api/pandas.Index.html#pandas.Index) constructor
- [x] Removed argument inplace from Categorical.remove_unused_categories() (#932)
- [ ] Remove keywords convert_float and mangle_dupe_cols from [read_excel()](https://pandas.pydata.org/docs/reference/api/pandas.read_excel.html#pandas.read_excel)
- [ ] Remove keyword mangle_dupe_cols from [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv) and [read_table()](https://pandas.pydata.org/docs/reference/api/pandas.read_table.html#pandas.read_table)
- [ ] Removed errors keyword from [DataFrame.where()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.where.html#pandas.DataFrame.where), [Series.where()](https://pandas.pydata.org/docs/reference/api/pandas.Series.where.html#pandas.Series.where), [DataFrame.mask()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.mask.html#pandas.DataFrame.mask) and [Series.mask()](https://pandas.pydata.org/docs/reference/api/pandas.Series.mask.html#pandas.Series.mask)
- [ ] Disallow passing non-keyword arguments to [read_excel()] (https://pandas.pydata.org/docs/reference/api/pandas.read_excel.html#pandas.read_excel) except io and sheet_name
- [ ] Disallow passing non-keyword arguments to [DataFrame.drop()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.drop.html#pandas.DataFrame.drop) and [Series.drop()](https://pandas.pydata.org/docs/reference/api/pandas.Series.drop.html#pandas.Series.drop) except labels
- [ ] Disallow passing non-keyword arguments to [DataFrame.fillna()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.fillna.html#pandas.DataFrame.fillna) and [Series.fillna()](https://pandas.pydata.org/docs/reference/api/pandas.Series.fillna.html#pandas.Series.fillna) except value
- [ ] Disallow passing non-keyword arguments to StringMethods.split() and StringMethods.rsplit() except for pat 
- [ ] Disallow passing non-keyword arguments to [DataFrame.set_index()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.set_index.html#pandas.DataFrame.set_index) except keys
- [ ] Disallow passing non-keyword arguments to Resampler.interpolate() except method
- [ ] Disallow passing non-keyword arguments to [DataFrame.reset_index()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.reset_index.html#pandas.DataFrame.reset_index) and [Series.reset_index()](https://pandas.pydata.org/docs/reference/api/pandas.Series.reset_index.html#pandas.Series.reset_index) except level
- [ ] Disallow passing non-keyword arguments to [DataFrame.dropna()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.dropna.html#pandas.DataFrame.dropna) and [Series.dropna()](https://pandas.pydata.org/docs/reference/api/pandas.Series.dropna.html#pandas.Series.dropna)
- [ ] Disallow passing non-keyword arguments to ExtensionArray.argsort()
- [ ] Disallow passing non-keyword arguments to Categorical.sort_values()
- [ ] Disallow passing non-keyword arguments to [Index.drop_duplicates()](https://pandas.pydata.org/docs/reference/api/pandas.Index.drop_duplicates.html#pandas.Index.drop_duplicates) and [Series.drop_duplicates()](https://pandas.pydata.org/docs/reference/api/pandas.Series.drop_duplicates.html#pandas.Series.drop_duplicates)
- [ ] Disallow passing non-keyword arguments to [DataFrame.drop_duplicates()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.drop_duplicates.html#pandas.DataFrame.drop_duplicates) except for subset
- [ ] Disallow passing non-keyword arguments to [DataFrame.sort_index()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.sort_index.html#pandas.DataFrame.sort_index) and [Series.sort_index()](https://pandas.pydata.org/docs/reference/api/pandas.Series.sort_index.html#pandas.Series.sort_index)
- [ ] Disallow passing non-keyword arguments to [DataFrame.interpolate()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.interpolate.html#pandas.DataFrame.interpolate) and [Series.interpolate()](https://pandas.pydata.org/docs/reference/api/pandas.Series.interpolate.html#pandas.Series.interpolate) except for method
- [ ] Disallow passing non-keyword arguments to [DataFrame.any()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.any.html#pandas.DataFrame.any) and [Series.any()](https://pandas.pydata.org/docs/reference/api/pandas.Series.any.html#pandas.Series.any)
- [ ] Disallow passing non-keyword arguments to [Index.set_names()](https://pandas.pydata.org/docs/reference/api/pandas.Index.set_names.html#pandas.Index.set_names) except for names
- [ ] Disallow passing non-keyword arguments to [Index.join()](https://pandas.pydata.org/docs/reference/api/pandas.Index.join.html#pandas.Index.join) except for other
- [ ] Disallow passing non-keyword arguments to [concat()](https://pandas.pydata.org/docs/reference/api/pandas.concat.html#pandas.concat) except for objs
- [ ] Disallow passing non-keyword arguments to [pivot()](https://pandas.pydata.org/docs/reference/api/pandas.pivot.html#pandas.pivot) except for data
- [ ] Disallow passing non-keyword arguments to [DataFrame.pivot()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.pivot.html#pandas.DataFrame.pivot)
- [ ] Disallow passing non-keyword arguments to [read_html()](https://pandas.pydata.org/docs/reference/api/pandas.read_html.html#pandas.read_html) except for io
- [ ] Disallow passing non-keyword arguments to [read_json()](https://pandas.pydata.org/docs/reference/api/pandas.read_json.html#pandas.read_json) except for path_or_buf
- [ ] Disallow passing non-keyword arguments to [read_sas()](https://pandas.pydata.org/docs/reference/api/pandas.read_sas.html#pandas.read_sas) except for filepath_or_buffer
- [ ] Disallow passing non-keyword arguments to [read_stata()](https://pandas.pydata.org/docs/reference/api/pandas.read_stata.html#pandas.read_stata) except for filepath_or_buffer
- [ ] Disallow passing non-keyword arguments to [read_csv()](https://pandas.pydata.org/docs/reference/api/pandas.read_csv.html#pandas.read_csv) except filepath_or_buffer
- [ ] Disallow passing non-keyword arguments to [read_table()](https://pandas.pydata.org/docs/reference/api/pandas.read_table.html#pandas.read_table) except filepath_or_buffer
- [ ] Disallow passing non-keyword arguments to [read_fwf()](https://pandas.pydata.org/docs/reference/api/pandas.read_fwf.html#pandas.read_fwf) except filepath_or_buffer
- [ ] Disallow passing non-keyword arguments to [read_xml()](https://pandas.pydata.org/docs/reference/api/pandas.read_xml.html#pandas.read_xml) except for path_or_buffer
- [ ] Disallow passing non-keyword arguments to [Series.mask()](https://pandas.pydata.org/docs/reference/api/pandas.Series.mask.html#pandas.Series.mask) and [DataFrame.mask()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.mask.html#pandas.DataFrame.mask) except cond and other
- [ ] Disallow passing non-keyword arguments to [DataFrame.to_stata()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_stata.html#pandas.DataFrame.to_stata) except for path
- [ ] Disallow passing non-keyword arguments to [DataFrame.where()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.where.html#pandas.DataFrame.where) and [Series.where()](https://pandas.pydata.org/docs/reference/api/pandas.Series.where.html#pandas.Series.where) except for cond and other
- [ ] Disallow passing non-keyword arguments to [Series.set_axis()](https://pandas.pydata.org/docs/reference/api/pandas.Series.set_axis.html#pandas.Series.set_axis) and [DataFrame.set_axis()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.set_axis.html#pandas.DataFrame.set_axis) except for labels
- [ ] Disallow passing non-keyword arguments to [Series.rename_axis()](https://pandas.pydata.org/docs/reference/api/pandas.Series.rename_axis.html#pandas.Series.rename_axis) and [DataFrame.rename_axis()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.rename_axis.html#pandas.DataFrame.rename_axis) except for mapper
- [ ] Disallow passing non-keyword arguments to [Series.clip()](https://pandas.pydata.org/docs/reference/api/pandas.Series.clip.html#pandas.Series.clip) and [DataFrame.clip()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.clip.html#pandas.DataFrame.clip)
- [ ] Disallow passing non-keyword arguments to [Series.bfill()](https://pandas.pydata.org/docs/reference/api/pandas.Series.bfill.html#pandas.Series.bfill), [Series.ffill()](https://pandas.pydata.org/docs/reference/api/pandas.Series.ffill.html#pandas.Series.ffill), [DataFrame.bfill()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.bfill.html#pandas.DataFrame.bfill) and [DataFrame.ffill()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.ffill.html#pandas.DataFrame.ffill)
- [ ] Disallow passing non-keyword arguments to [DataFrame.replace()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.replace.html#pandas.DataFrame.replace), [Series.replace()](https://pandas.pydata.org/docs/reference/api/pandas.Series.replace.html#pandas.Series.replace) except for to_replace and value
- [ ] Disallow passing non-keyword arguments to [DataFrame.sort_values()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.sort_values.html#pandas.DataFrame.sort_values) except for by
- [ ] Disallow passing non-keyword arguments to [Series.sort_values()](https://pandas.pydata.org/docs/reference/api/pandas.Series.sort_values.html#pandas.Series.sort_values)
- [ ] Disallow passing non-keyword arguments to [DataFrame.reindex()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.reindex.html#pandas.DataFrame.reindex) except for labels
- [ ] Disallowed constructing [Categorical](https://pandas.pydata.org/docs/reference/api/pandas.Categorical.html#pandas.Categorical) with scalar data
- [ ] Removed Rolling.validate(), Expanding.validate(), and ExponentialMovingWindow.validate()
- [ ] Removed Rolling.win_type returning "freq"
- [ ] Removed Rolling.is_datetimelike
- [ ] Removed the level keyword in [DataFrame](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.html#pandas.DataFrame) and [Series](https://pandas.pydata.org/docs/reference/api/pandas.Series.html#pandas.Series) aggregations
- [ ] Removed deprecated Timedelta.delta(), Timedelta.is_populated(), and Timedelta.freq
- [ ] Removed deprecated NaT.freq
- [ ] Removed deprecated Categorical.replace()
- [ ] Removed the numeric_only keyword from Categorical.min() and Categorical.max()
- [ ] Removed is_extension_type() in favor of is_extension_array_dtype()
- [ ] Removed .ExponentialMovingWindow.vol
- [x] Removed Index.get_value() and Index.set_value()  (#931)
- [x] Removed Series.slice_shift() and DataFrame.slice_shift() (#930)
- [ ] Remove DataFrameGroupBy.pad() and DataFrameGroupBy.backfill()
- [ ] Remove numpy argument from [read_json()](https://pandas.pydata.org/docs/reference/api/pandas.read_json.html#pandas.read_json)
- [x] Disallow passing abbreviations for orient in [DataFrame.to_dict()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_dict.html#pandas.DataFrame.to_dict)  #638
- [ ] Removed get_offset
- [x] ~~Removed the warn keyword in [infer_freq()]~~(https://pandas.pydata.org/docs/reference/api/pandas.infer_freq.html#pandas.infer_freq)
- [ ] Removed the include_start and include_end arguments in [DataFrame.between_time()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.between_time.html#pandas.DataFrame.between_time)
- [ ] Removed the closed argument in [date_range()](https://pandas.pydata.org/docs/reference/api/pandas.date_range.html#pandas.date_range) and [bdate_range()](https://pandas.pydata.org/docs/reference/api/pandas.bdate_range.html#pandas.bdate_range)
- [ ] Removed the center keyword in [DataFrame.expanding()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.expanding.html#pandas.DataFrame.expanding)
- [ ] Removed the truediv keyword from [eval()](https://pandas.pydata.org/docs/reference/api/pandas.eval.html#pandas.eval)
- [ ] Removed the method and tolerance arguments in [Index.get_loc()](https://pandas.pydata.org/docs/reference/api/pandas.Index.get_loc.html#pandas.Index.get_loc)
- [ ] Removed the pandas.datetime submodule
- [ ] Removed the pandas.np submodule
- [ ] Removed pandas.util.testing
- [ ] Removed Series.str.__iter__()
- [ ] Removed pandas.SparseArray
- [ ] Removed pandas.SparseSeries and pandas.SparseDataFrame
- [ ] Enforced disallowing passing an integer fill_value to [DataFrame.shift()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.shift.html#pandas.DataFrame.shift) and Series.shift`() with datetime64, timedelta64, or period dtypes
- [ ] Enforced disallowing a string column label into times in [DataFrame.ewm()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.ewm.html#pandas.DataFrame.ewm)
- [ ] Enforced disallowing passing True and False into inclusive in [Series.between()](https://pandas.pydata.org/docs/reference/api/pandas.Series.between.html#pandas.Series.between) in favor of "both" and "neither" respectively
- [ ] Enforced disallowing the use of **kwargs in [ExcelWriter](https://pandas.pydata.org/docs/reference/api/pandas.ExcelWriter.html#pandas.ExcelWriter)
- [ ] Enforced disallowing a tuple of column labels into DataFrameGroupBy.__getitem__()
- [ ] Enforced disallowing set or dict indexers in __getitem__ and __setitem__ methods
- [ ] Enforced disallowing dict or set objects in suffixes in [merge()](https://pandas.pydata.org/docs/reference/api/pandas.merge.html#pandas.merge)
- [ ] Removed setting Categorical._codes directly 
- [ ] Removed setting Categorical.categories directly 
- [x] Removed argument inplace from Categorical.add_categories(), Categorical.remove_categories(), Categorical.set_categories(), Categorical.rename_categories(), Categorical.reorder_categories(), (#932)
- [ ] Removed argument inplace from Categorical.set_ordered(), Categorical.as_ordered(), Categorical.as_unordered()
- [ ] Renamed fname to path in [DataFrame.to_parquet()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_parquet.html#pandas.DataFrame.to_parquet), [DataFrame.to_stata()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_stata.html#pandas.DataFrame.to_stata) and [DataFrame.to_feather()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_feather.html#pandas.DataFrame.to_feather)
- [ ] Removed the display.column_space option
- [ ] Removed the deprecated method mad from pandas classes 
- [x] Removed the deprecated method tshift from pandas classes (#930)
- [ ] Changed behavior of [Index.ravel()](https://pandas.pydata.org/docs/reference/api/pandas.Index.ravel.html#pandas.Index.ravel) to return a view on the original [Index](https://pandas.pydata.org/docs/reference/api/pandas.Index.html#pandas.Index) instead of a np.ndarray
- [ ] Removed the deprecated base and loffset arguments from [pandas.DataFrame.resample()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.resample.html#pandas.DataFrame.resample), [pandas.Series.resample()](https://pandas.pydata.org/docs/reference/api/pandas.Series.resample.html#pandas.Series.resample) and [pandas.Grouper](https://pandas.pydata.org/docs/reference/api/pandas.Grouper.html#pandas.Grouper)
- [x] ~~Change the default argument of regex for [Series.str.replace()](https://pandas.pydata.org/docs/reference/api/pandas.Series.str.replace.html#pandas.Series.str.replace) from True to False~~
- [ ] Changed behavior of comparison of a [Timestamp](https://pandas.pydata.org/docs/reference/api/pandas.Timestamp.html#pandas.Timestamp) with a datetime.date object; these now compare as un-equal and raise on inequality comparisons
- [ ] Changed behavior of comparison of NaT with a datetime.date object; these now raise on inequality comparisons
- [x] Removed na_sentinel argument from [factorize()](https://pandas.pydata.org/docs/reference/api/pandas.factorize.html#pandas.factorize), [Index.factorize()](https://pandas.pydata.org/docs/reference/api/pandas.Index.factorize.html#pandas.Index.factorize), and [ExtensionArray.factorize()] (https://pandas.pydata.org/docs/reference/api/pandas.api.extensions.ExtensionArray.factorize.html#pandas.api.extensions.ExtensionArray.factorize) #1037
- [ ] Enforced deprecation disallowing passing numeric_only=True to [Series](https://pandas.pydata.org/docs/reference/api/pandas.Series.html#pandas.Series) reductions (rank, any, all, …) with non-numeric dtype
- [x] ~~Changed default of numeric_only to False in all DataFrame methods with that argument~~
- [x] ~~Changed default of numeric_only to False in [Series.rank()]~~(https://pandas.pydata.org/docs/reference/api/pandas.Series.rank.html#pandas.Series.rank)
- [x] ~~Changed default of numeric_only in various DataFrameGroupBy methods; all methods now default to numeric_only=False ~~
- [x] ~~Changed default of numeric_only to False in Resampler methods ~~
- [x] ~~Removed deprecated methods ExcelWriter.write_cells(), ExcelWriter.save(), ExcelWriter.cur_sheet(), ExcelWriter.handles(), ExcelWriter.path()~~
- [x] ~~The [ExcelWriter](https://pandas.pydata.org/docs/reference/api/pandas.ExcelWriter.html#pandas.ExcelWriter) attribute book can no longer be set~~
- [ ] Removed unused *args and **kwargs in Rolling, Expanding, and ExponentialMovingWindow ops
- [x] ~~Removed the deprecated argument line_terminator from [DataFrame.to_csv()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.to_csv.html#pandas.DataFrame.to_csv)~~
- [x] ~~Removed the deprecated argument label from [lreshape()](https://pandas.pydata.org/docs/reference/api/pandas.lreshape.html#pandas.lreshape)~~
- [x] ~~Arguments after expr in [DataFrame.eval()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.eval.html#pandas.DataFrame.eval) and [DataFrame.query()](https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.query.html#pandas.DataFrame.query) are keyword-only~~
- [x] ~~Removed Index._get_attributes_dict()~~
- [x] ~~Removed Series.__array_wrap__()~~



Discussion / hints:
Is the cut-off for removal of support for 1.5 effectively immediately? For instance, there are bugs constantly being fixed in the annotations, and so I currently stay up-to-date on the version. However I don't know if I'll be able to easily upgrade to 2.0 without breaking anything, and so I'd probably defer that upgrade. It seems 2.0 brings a fair amount of backwards-incompatible changes.
> Is the cut-off for removal of support for 1.5 effectively immediately? For instance, there are bugs constantly being fixed in the annotations, and so I currently stay up-to-date on the version. However I don't know if I'll be able to easily upgrade to 2.0 without breaking anything, and so I'd probably defer that upgrade. It seems 2.0 brings a fair amount of backwards-incompatible changes.

Yes.  The idea is that we want to encourage people to use the 2.0 API.  I think that the 2.0 stubs (when released) will still work with 1.5 code, and, if not, they are telling you places in your code that you should change in order to be compatible with 2.0 in the future.

As an example, anything that was deprecated in 1.5 was already removed from the stubs.

@Dr-Irv I think i have added the `dtype_backend` in `series.convert_dtypes` whch  is covered in #655 
> @Dr-Irv I think i have added the `dtype_backend` in `series.convert_dtypes` is covered in #655

Thanks.  I updated the list.
@Dr-Irv i think you can mark this `Added name parameter to IntervalIndex.from_breaks(), IntervalIndex.from_arrays(), IntervalIndex.from_tuples() ` as completed as the name parameter is already added in these.
> @Dr-Irv i think you can mark this `Added name parameter to IntervalIndex.from_breaks(), IntervalIndex.from_arrays(), IntervalIndex.from_tuples() ` as completed as the name parameter is already added in these.

Thanks.  I've done that update
What is actually needed to be done to disallow non-keyword arguments? Most of the stubs already have the `*` in the overloads, is it just a matter of bring in the function def too for those overloaded ones? Lets just use `drop` as an example. 

If so I can take those over.
> What is actually needed to be done to disallow non-keyword arguments? Most of the stubs already have the `*` in the overloads, is it just a matter of bring in the function def too for those overloaded ones? Lets just use `drop` as an example.
> 
> If so I can take those over.

It's a mix of using `*` and `/`.  See https://peps.python.org/pep-0570/#syntax-and-semantics

PR's are welcome.  Maybe do one function so we can agree on the approach, then you can expand it to others.


Fix patch:
diff --git a/pandas-stubs/core/arrays/datetimelike.pyi b/pandas-stubs/core/arrays/datetimelike.pyi
index b5b5dba7..fc9548b0 100644
--- a/pandas-stubs/core/arrays/datetimelike.pyi
+++ b/pandas-stubs/core/arrays/datetimelike.pyi
@@ -5,16 +5,21 @@ from pandas.core.arrays.base import (
     ExtensionArray,
     ExtensionOpsMixin,
 )
+from typing_extensions import Self
 
 from pandas._libs import (
     NaT as NaT,
     NaTType as NaTType,
 )
+from pandas._typing import TimeUnit
 
 class DatelikeOps:
     def strftime(self, date_format): ...
 
 class TimelikeOps:
+    @property
+    def unit(self) -> TimeUnit: ...
+    def as_unit(self, unit: TimeUnit) -> Self: ...
     def round(self, freq, ambiguous: str = ..., nonexistent: str = ...): ...
     def floor(self, freq, ambiguous: str = ..., nonexistent: str = ...): ...
     def ceil(self, freq, ambiguous: str = ..., nonexistent: str = ...): ...
diff --git a/pandas-stubs/core/indexes/accessors.pyi b/pandas-stubs/core/indexes/accessors.pyi
index a974fa6a..437b8b19 100644
--- a/pandas-stubs/core/indexes/accessors.pyi
+++ b/pandas-stubs/core/indexes/accessors.pyi
@@ -36,6 +36,7 @@ from pandas._libs.tslibs import BaseOffset
 from pandas._libs.tslibs.offsets import DateOffset
 from pandas._typing import (
     TimestampConvention,
+    TimeUnit,
     np_ndarray_bool,
 )
 
@@ -154,16 +155,16 @@ class _DatetimeLikeOps(
 # type of the series, we don't know which kind of series was ...ed
 # in to the dt accessor
 
-_DTRoundingMethodReturnType = TypeVar(
-    "_DTRoundingMethodReturnType",
+_DTTimestampTimedeltaReturnType = TypeVar(
+    "_DTTimestampTimedeltaReturnType",
     Series,
-    TimedeltaSeries,
     TimestampSeries,
+    TimedeltaSeries,
     DatetimeIndex,
     TimedeltaIndex,
 )
 
-class _DatetimeRoundingMethods(Generic[_DTRoundingMethodReturnType]):
+class _DatetimeRoundingMethods(Generic[_DTTimestampTimedeltaReturnType]):
     def round(
         self,
         freq: str | BaseOffset | None,
@@ -173,7 +174,7 @@ class _DatetimeRoundingMethods(Generic[_DTRoundingMethodReturnType]):
             | timedelta
             | Timedelta
         ) = ...,
-    ) -> _DTRoundingMethodReturnType: ...
+    ) -> _DTTimestampTimedeltaReturnType: ...
     def floor(
         self,
         freq: str | BaseOffset | None,
@@ -183,7 +184,7 @@ class _DatetimeRoundingMethods(Generic[_DTRoundingMethodReturnType]):
             | timedelta
             | Timedelta
         ) = ...,
-    ) -> _DTRoundingMethodReturnType: ...
+    ) -> _DTTimestampTimedeltaReturnType: ...
     def ceil(
         self,
         freq: str | BaseOffset | None,
@@ -193,7 +194,7 @@ class _DatetimeRoundingMethods(Generic[_DTRoundingMethodReturnType]):
             | timedelta
             | Timedelta
         ) = ...,
-    ) -> _DTRoundingMethodReturnType: ...
+    ) -> _DTTimestampTimedeltaReturnType: ...
 
 _DTNormalizeReturnType = TypeVar(
     "_DTNormalizeReturnType", TimestampSeries, DatetimeIndex
@@ -202,9 +203,9 @@ _DTStrKindReturnType = TypeVar("_DTStrKindReturnType", Series[str], Index)
 _DTToPeriodReturnType = TypeVar("_DTToPeriodReturnType", PeriodSeries, PeriodIndex)
 
 class _DatetimeLikeNoTZMethods(
-    _DatetimeRoundingMethods[_DTRoundingMethodReturnType],
+    _DatetimeRoundingMethods[_DTTimestampTimedeltaReturnType],
     Generic[
-        _DTRoundingMethodReturnType,
+        _DTTimestampTimedeltaReturnType,
         _DTNormalizeReturnType,
         _DTStrKindReturnType,
         _DTToPeriodReturnType,
@@ -238,7 +239,7 @@ class _DatetimeNoTZProperties(
         _DTFreqReturnType,
     ],
     _DatetimeLikeNoTZMethods[
-        _DTRoundingMethodReturnType,
+        _DTTimestampTimedeltaReturnType,
         _DTNormalizeReturnType,
         _DTStrKindReturnType,
         _DTToPeriodReturnType,
@@ -246,7 +247,7 @@ class _DatetimeNoTZProperties(
     Generic[
         _DTFieldOpsReturnType,
         _DTBoolOpsReturnType,
-        _DTRoundingMethodReturnType,
+        _DTTimestampTimedeltaReturnType,
         _DTOtherOpsDateReturnType,
         _DTOtherOpsTimeReturnType,
         _DTFreqReturnType,
@@ -261,7 +262,7 @@ class DatetimeProperties(
     _DatetimeNoTZProperties[
         _DTFieldOpsReturnType,
         _DTBoolOpsReturnType,
-        _DTRoundingMethodReturnType,
+        _DTTimestampTimedeltaReturnType,
         _DTOtherOpsDateReturnType,
         _DTOtherOpsTimeReturnType,
         _DTFreqReturnType,
@@ -272,7 +273,7 @@ class DatetimeProperties(
     Generic[
         _DTFieldOpsReturnType,
         _DTBoolOpsReturnType,
-        _DTRoundingMethodReturnType,
+        _DTTimestampTimedeltaReturnType,
         _DTOtherOpsDateReturnType,
         _DTOtherOpsTimeReturnType,
         _DTFreqReturnType,
@@ -283,6 +284,9 @@ class DatetimeProperties(
 ):
     def to_pydatetime(self) -> np.ndarray: ...
     def isocalendar(self) -> DataFrame: ...
+    @property
+    def unit(self) -> TimeUnit: ...
+    def as_unit(self, unit: TimeUnit) -> _DTTimestampTimedeltaReturnType: ...
 
 _TDNoRoundingMethodReturnType = TypeVar(
     "_TDNoRoundingMethodReturnType", Series[int], Index
@@ -309,7 +313,10 @@ class TimedeltaProperties(
     Properties,
     _TimedeltaPropertiesNoRounding[Series[int], Series[float]],
     _DatetimeRoundingMethods[TimedeltaSeries],
-): ...
+):
+    @property
+    def unit(self) -> TimeUnit: ...
+    def as_unit(self, unit: TimeUnit) -> TimedeltaSeries: ...
 
 _PeriodDTReturnTypes = TypeVar("_PeriodDTReturnTypes", TimestampSeries, DatetimeIndex)
 _PeriodIntReturnTypes = TypeVar("_PeriodIntReturnTypes", Series[int], Index[int])
diff --git a/pandas-stubs/core/indexes/datetimelike.pyi b/pandas-stubs/core/indexes/datetimelike.pyi
index 5b138b74..fb27fae2 100644
--- a/pandas-stubs/core/indexes/datetimelike.pyi
+++ b/pandas-stubs/core/indexes/datetimelike.pyi
@@ -1,8 +1,12 @@
 from pandas.core.indexes.extension import ExtensionIndex
 from pandas.core.indexes.timedeltas import TimedeltaIndex
+from typing_extensions import Self
 
 from pandas._libs.tslibs import BaseOffset
-from pandas._typing import S1
+from pandas._typing import (
+    S1,
+    TimeUnit,
+)
 
 class DatetimeIndexOpsMixin(ExtensionIndex[S1]):
     @property
@@ -19,4 +23,7 @@ class DatetimeIndexOpsMixin(ExtensionIndex[S1]):
         self, other: DatetimeIndexOpsMixin
     ) -> TimedeltaIndex: ...
 
-class DatetimeTimedeltaMixin(DatetimeIndexOpsMixin[S1]): ...
+class DatetimeTimedeltaMixin(DatetimeIndexOpsMixin[S1]):
+    @property
+    def unit(self) -> TimeUnit: ...
+    def as_unit(self, unit: TimeUnit) -> Self: ...


Test patch:
diff --git a/tests/test_timefuncs.py b/tests/test_timefuncs.py
index eeb177b7..36dd6d54 100644
--- a/tests/test_timefuncs.py
+++ b/tests/test_timefuncs.py
@@ -5,6 +5,7 @@
     TYPE_CHECKING,
     Any,
     Optional,
+    cast,
 )
 
 import numpy as np
@@ -24,6 +25,8 @@
     from pandas._typing import FulldatetimeDict
 else:
     FulldatetimeDict = Any
+from pandas._typing import TimeUnit
+
 from tests import (
     TYPE_CHECKING_INVALID_USAGE,
     check,
@@ -428,6 +431,11 @@ def test_series_dt_accessors() -> None:
     )
     check(assert_type(s0.dt.month_name(), "pd.Series[str]"), pd.Series, str)
     check(assert_type(s0.dt.day_name(), "pd.Series[str]"), pd.Series, str)
+    check(assert_type(s0.dt.unit, TimeUnit), str)
+    check(assert_type(s0.dt.as_unit("s"), "TimestampSeries"), pd.Series, pd.Timestamp)
+    check(assert_type(s0.dt.as_unit("ms"), "TimestampSeries"), pd.Series, pd.Timestamp)
+    check(assert_type(s0.dt.as_unit("us"), "TimestampSeries"), pd.Series, pd.Timestamp)
+    check(assert_type(s0.dt.as_unit("ns"), "TimestampSeries"), pd.Series, pd.Timestamp)
 
     i1 = pd.period_range(start="2022-06-01", periods=10)
 
@@ -455,6 +463,35 @@ def test_series_dt_accessors() -> None:
     check(assert_type(s2.dt.components, pd.DataFrame), pd.DataFrame)
     check(assert_type(s2.dt.to_pytimedelta(), np.ndarray), np.ndarray)
     check(assert_type(s2.dt.total_seconds(), "pd.Series[float]"), pd.Series, float)
+    check(assert_type(s2.dt.unit, TimeUnit), str)
+    check(assert_type(s2.dt.as_unit("s"), "TimedeltaSeries"), pd.Series, pd.Timedelta)
+    check(assert_type(s2.dt.as_unit("ms"), "TimedeltaSeries"), pd.Series, pd.Timedelta)
+    check(assert_type(s2.dt.as_unit("us"), "TimedeltaSeries"), pd.Series, pd.Timedelta)
+    check(assert_type(s2.dt.as_unit("ns"), "TimedeltaSeries"), pd.Series, pd.Timedelta)
+
+    # Checks for general Series other than TimestampSeries and TimedeltaSeries
+
+    s4 = cast(
+        "pd.Series[pd.Timestamp]",
+        pd.Series([pd.Timestamp("2024-01-01"), pd.Timestamp("2024-01-02")]),
+    )
+
+    check(assert_type(s4.dt.unit, TimeUnit), str)
+    check(assert_type(s4.dt.as_unit("s"), pd.Series), pd.Series, pd.Timestamp)
+    check(assert_type(s4.dt.as_unit("ms"), pd.Series), pd.Series, pd.Timestamp)
+    check(assert_type(s4.dt.as_unit("us"), pd.Series), pd.Series, pd.Timestamp)
+    check(assert_type(s4.dt.as_unit("ns"), pd.Series), pd.Series, pd.Timestamp)
+
+    s5 = cast(
+        "pd.Series[pd.Timedelta]",
+        pd.Series([pd.Timedelta("1 day"), pd.Timedelta("2 days")]),
+    )
+
+    check(assert_type(s5.dt.unit, TimeUnit), str)
+    check(assert_type(s5.dt.as_unit("s"), pd.Series), pd.Series, pd.Timedelta)
+    check(assert_type(s5.dt.as_unit("ms"), pd.Series), pd.Series, pd.Timedelta)
+    check(assert_type(s5.dt.as_unit("us"), pd.Series), pd.Series, pd.Timedelta)
+    check(assert_type(s5.dt.as_unit("ns"), pd.Series), pd.Series, pd.Timedelta)
 
 
 def test_datetimeindex_accessors() -> None:
@@ -522,6 +559,11 @@ def test_datetimeindex_accessors() -> None:
     check(assert_type(i0.month_name(), pd.Index), pd.Index, str)
     check(assert_type(i0.day_name(), pd.Index), pd.Index, str)
     check(assert_type(i0.is_normalized, bool), bool)
+    check(assert_type(i0.unit, TimeUnit), str)
+    check(assert_type(i0.as_unit("s"), pd.DatetimeIndex), pd.DatetimeIndex)
+    check(assert_type(i0.as_unit("ms"), pd.DatetimeIndex), pd.DatetimeIndex)
+    check(assert_type(i0.as_unit("us"), pd.DatetimeIndex), pd.DatetimeIndex)
+    check(assert_type(i0.as_unit("ns"), pd.DatetimeIndex), pd.DatetimeIndex)
 
 
 def test_timedeltaindex_accessors() -> None:
@@ -542,6 +584,11 @@ def test_timedeltaindex_accessors() -> None:
         assert_type(i0.floor("D"), pd.TimedeltaIndex), pd.TimedeltaIndex, pd.Timedelta
     )
     check(assert_type(i0.ceil("D"), pd.TimedeltaIndex), pd.TimedeltaIndex, pd.Timedelta)
+    check(assert_type(i0.unit, TimeUnit), str)
+    check(assert_type(i0.as_unit("s"), pd.TimedeltaIndex), pd.TimedeltaIndex)
+    check(assert_type(i0.as_unit("ms"), pd.TimedeltaIndex), pd.TimedeltaIndex)
+    check(assert_type(i0.as_unit("us"), pd.TimedeltaIndex), pd.TimedeltaIndex)
+    check(assert_type(i0.as_unit("ns"), pd.TimedeltaIndex), pd.TimedeltaIndex)
 
 
 def test_periodindex_accessors() -> None: