Correctly handle resolver info in binary exporter - #5546
#5546Merged
NinoFloris merged 1 commit intoJan 24, 2024
mainnpgsql/npgsql:mainfrom
exporter-converter-resolvernpgsql/npgsql:exporter-converter-resolverCopy head branch name to clipboard
Merged
Correctly handle resolver info in binary exporter#5546NinoFloris merged 1 commit intomainnpgsql/npgsql:mainfrom exporter-converter-resolvernpgsql/npgsql:exporter-converter-resolverCopy head branch name to clipboard
NinoFloris merged 1 commit into
mainnpgsql/npgsql:mainfrom
exporter-converter-resolvernpgsql/npgsql:exporter-converter-resolverCopy head branch name to clipboard
Conversation
NinoFloris
force-pushed
the
exporter-converter-resolver
branch
from
January 24, 2024 21:10
6436979 to
bb2a6b3
Compare
NinoFloris
commented
Jan 24, 2024
| // Binary export has no type info so we only do caller-directed interpretation of data. | ||
| return info.Bind(new Field("?", info.PgTypeId!.Value, -1), DataFormat.Binary); | ||
| return info.Bind(new Field("?", | ||
| info.PgTypeId ?? ((PgResolverTypeInfo)info).GetDefaultResolution(null).PgTypeId, -1), DataFormat.Binary); |
Member
Author
There was a problem hiding this comment.
We need to do this GetDefaultResolution crap as we do not know what we should pick otherwise. (COPY being untyped)
roji
approved these changes
Jan 24, 2024
| case PgResolverTypeInfo resolverInfo: | ||
| var resolution = resolverInfo.GetResolution(field); | ||
| if (!HasCachedInfo(resolution.Converter) | ||
| if (HasCachedInfo(resolution.Converter) |
Member
There was a problem hiding this comment.
Ha, the good old inversed logic bug...
Member
Author
There was a problem hiding this comment.
Yup, wasn't noticed as it was only a problem for reads over undecided type infos.
So never, except for binary export :')
Member
Author
|
Backported to 8.0.2 via 31941d1 |
This was referenced Oct 29, 2025
This was referenced Nov 5, 2025
This was referenced Nov 17, 2025
This was referenced Dec 1, 2025
This was referenced Dec 8, 2025
This was referenced Dec 17, 2025
Open
This was referenced Jan 5, 2026
This was referenced Apr 2, 2026
This was referenced May 6, 2026
This was referenced May 21, 2026
This was referenced Jun 1, 2026
This was referenced Jul 14, 2026
Closed
This was referenced Jul 25, 2026
Open
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #5520