Details
-
Improvement
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
None
Description
The return type of this method should really be `Instant`, but that would be a breaking change.
Instead, we can deprecate the `expiry()` method and add an `expiryTime()` method that returns an Instant.
Attachments
Issue Links
- mentioned in
-
Page Loading...
For Gerrit Dashboard: PYCBC-999 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
143304,5 | PYCBC-999 Deprecate GetResult.expiry() | master | couchbase-python-client | Status: MERGED | +2 | +1 |
Added a 'deprecated' decorator in couchbase_core/supportability.py, akin to the existing @uncommitted, and decorated GetResult.expiry with it.
@deprecated adds "This is a deprecated API, use expiryTime instead." to the GetResult.expiry docstring and also issues a warning to the same effect.
Added new property 'expiryTime' which returns an "instant" i.e. unix timestamp.
Modified uses of the expiry property to use expiryTime in tests_v3/cases/collection_t.py, and added a test that the expiry property still works as before.
Generated the Python API docs and verified that GetResult.expiry is described as deprecated.