diff --git a/pandas/_libs/tslibs/timestamps.pyx b/pandas/_libs/tslibs/timestamps.pyx index 1d21f602fac05..349cb0d50c46e 100644 --- a/pandas/_libs/tslibs/timestamps.pyx +++ b/pandas/_libs/tslibs/timestamps.pyx @@ -157,14 +157,7 @@ cdef inline _Timestamp create_timestamp_from_ts( def _unpickle_timestamp(value, freq, tz, reso=NPY_FR_ns): # GH#41949 dont warn on unpickle if we have a freq - if reso == NPY_FR_ns: - ts = Timestamp(value, tz=tz) - else: - if tz is not None: - raise NotImplementedError - abbrev = npy_unit_to_abbrev(reso) - dt64 = np.datetime64(value, abbrev) - ts = Timestamp._from_dt64(dt64) + ts = Timestamp._from_value_and_reso(value, reso, tz) ts._set_freq(freq) return ts diff --git a/pandas/tests/scalar/timestamp/test_timestamp.py b/pandas/tests/scalar/timestamp/test_timestamp.py index 79c8a300b34e3..2f9b030e5d627 100644 --- a/pandas/tests/scalar/timestamp/test_timestamp.py +++ b/pandas/tests/scalar/timestamp/test_timestamp.py @@ -22,6 +22,7 @@ from pandas._libs.tslibs.timezones import ( dateutil_gettz as gettz, get_timezone, + maybe_get_tz, tz_compare, ) from pandas.errors import OutOfBoundsDatetime @@ -836,7 +837,10 @@ def test_cmp_cross_reso_reversed_dt64(self): assert other.asm8 < ts - def test_pickle(self, ts): + def test_pickle(self, ts, tz_aware_fixture): + tz = tz_aware_fixture + tz = maybe_get_tz(tz) + ts = Timestamp._from_value_and_reso(ts.value, ts._reso, tz) rt = tm.round_trip_pickle(ts) assert rt._reso == ts._reso assert rt == ts