Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1ijApZ-0007jV-AG for pgsql-general@arkaria.postgresql.org; Sun, 22 Dec 2019 23:40:13 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1ijApY-0001l5-41 for pgsql-general@arkaria.postgresql.org; Sun, 22 Dec 2019 23:40:12 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1ijApX-0001ky-N0 for pgsql-general@lists.postgresql.org; Sun, 22 Dec 2019 23:40:11 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ijApV-0003Az-CM for pgsql-general@lists.postgresql.org; Sun, 22 Dec 2019 23:40:10 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id xBMNe6KE009761; Sun, 22 Dec 2019 18:40:06 -0500 From: Tom Lane To: Andrei Pozolotin cc: pgsql-general@lists.postgresql.org Subject: Re: Question: what is proper way to define python function as event_trigger? In-reply-to: <0d6c5bdc3ab532bc3240cfb14bc55ce9@gmail.com> References: <0d6c5bdc3ab532bc3240cfb14bc55ce9@gmail.com> Comments: In-reply-to Andrei Pozolotin message dated "Sun, 22 Dec 2019 16:27:02 -0600" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <9759.1577058006.1@sss.pgh.pa.us> Date: Sun, 22 Dec 2019 18:40:06 -0500 Message-ID: <9760.1577058006@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Andrei Pozolotin writes: > 1. any attempt to define python function as an event_trigger, i.e.: AFAICS, there's not really any event trigger support in plpython. That feature has only been built out in the other three PLs. Somebody oughta fix this sometime, I guess, but it evidently hasn't been high priority. If you feel like working on it, you could look at commits e5dc4cc24d2e1e94ac572a2c64103710bf15d21e (for plperl) and/or a5036ca998a6058f60913d43a80badfcbb65f5bb (for pltcl). regards, tom lane