pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Tomas Vondra <tomas.vondra@2ndquadrant.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: [HACKERS] user-defined numeric data types triggering ERROR: unsupported type
Date: Mon, 05 Mar 2018 14:34:16 -0500
Message-ID: <26233.1520278456@sss.pgh.pa.us> (raw)
In-Reply-To: <c7fc30bf-ff2d-dd88-ae28-2b5334003fb4@2ndquadrant.com>
References: <b68441b6-d18f-13ab-b43b-9a72188a4e02@2ndquadrant.com>
	<9389.1506003842@sss.pgh.pa.us>
	<4b444362-4240-49e0-3523-724e5932b060@2ndquadrant.com>
	<24767.1506180446@sss.pgh.pa.us>
	<d526eb53-dbd6-d414-8e5d-21e644ce4549@2ndquadrant.com>
	<14597.1520038563@sss.pgh.pa.us>
	<42f4e37e-f923-6ea9-4172-cdec5a8c2d25@2ndquadrant.com>
	<b5cede7b-354b-83e6-ab1f-7a1bf8a232fa@2ndquadrant.com>
	<11916.1520127473@sss.pgh.pa.us>
	<82f29126-df5a-d4bc-f5b5-47233e29aaa6@2ndquadrant.com>
	<15879.1520182782@sss.pgh.pa.us>
	<07b0dcd6-45f7-a2d3-99c6-115490b2cc98@2ndquadrant.com>
	<25629.1520192235@sss.pgh.pa.us>
	<a105b486-b94d-8335-5a91-160e0b0d264b@2ndquadrant.com>
	<29012.1520196416@sss.pgh.pa.us>
	<c7fc30bf-ff2d-dd88-ae28-2b5334003fb4@2ndquadrant.com>

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




view thread (18+ messages)  latest in thread

Message-ID: <26233.1520278456@sss.pgh.pa.us>
Permalink:  ../26233.1520278456@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/26233.1520278456@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, tomas.vondra@2ndquadrant.com
  Subject: Re: [HACKERS] user-defined numeric data types triggering ERROR: unsupported type
  In-Reply-To: <26233.1520278456@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox