Re: [HACKERS] user-defined numeric data types triggering ERROR: unsupported type - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [HACKERS] user-defined numeric data types triggering ERROR: unsupported type
Date
Msg-id 26233.1520278456@sss.pgh.pa.us
Whole thread Raw
In response to Re: [HACKERS] user-defined numeric data types triggering ERROR:unsupported type  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
Responses Re: [HACKERS] user-defined numeric data types triggering ERROR:unsupported type  (Tomas Vondra <tomas.vondra@2ndquadrant.com>)
List pgsql-hackers
Tomas Vondra <tomas.vondra@2ndquadrant.com> writes:
> On 03/04/2018 09:46 PM, Tom Lane wrote:
>> Well, I think the existing bytea bug is a counterexample to that.  If
>> someone were to repeat that mistake with, say, UUID, these tests would not
>> catch it, because none of them would exercise UUID-vs-something-else.
>> For that matter, your statement is false on its face, because even if
>> somebody tried to add say uuid-versus-int8, these tests would not catch
>> lack of support for that in convert_to_scalar unless the specific case of
>> uuid-versus-int8 were added to the tests.

> I suspect we're simply having different expectations what the tests
> could/should protect against - my intention was to make sure someone
> does not break convert_to_scalar for the currently handled types.

I concur that we could use better test coverage for the existing
code --- the coverage report is pretty bleak there.  But I think we
could improve that just by testing with the existing operators.  I do
not see much use in checking that unsupported cross-type cases fail
cleanly, because there isn't a practical way to have full coverage
for such a concern.

            regards, tom lane


pgsql-hackers by date:

Previous
From: David Steele
Date:
Subject: Re: [HACKERS] PoC: custom signal handler for extensions
Next
From: Peter Eisentraut
Date:
Subject: Re: Kerberos test suite