Open
Description
Describe the bug
Upon upgrading my dependencies I got a deprecation warning for PostgresDataConvertible
, urging me to upgrade to the newer protocols, but when I attempted to upgrade, I got hit with decoding failures for typeMismatch
due to SQLRow.decode
no longer getting the right type.
To Reproduce
Here are the helpers I'm using, including the conformance at the bottom of the file:
Updating the conformance to the following breaks the helpers above:
extension Tagged: PostgresDecodable where RawValue: PostgresDecodable {
public init(
from byteBuffer: inout ByteBuffer,
type: PostgresDataType,
format: PostgresFormat,
context: PostgresDecodingContext<some PostgresJSONDecoder>
) throws {
self.init(
try RawValue(
from: &byteBuffer,
type: type,
format: format,
context: context
)
)
}
}
Expected behavior
I expect a deprecation warning pushing me to adopt a new API to be compatible with the existing APIs I adopt from PostgresKit.
Environment
- postgres-nio 1.18.0
- postgres-kit 2.12.2