Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sHq1A-00B7kx-HU for pgsql-hackers@arkaria.postgresql.org; Thu, 13 Jun 2024 19:21:52 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.94.2) (envelope-from ) id 1sHq0A-00672v-Ad for pgsql-hackers@arkaria.postgresql.org; Thu, 13 Jun 2024 19:20:51 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1sHq0A-00672n-0k for pgsql-hackers@lists.postgresql.org; Thu, 13 Jun 2024 19:20:50 +0000 Received: from mail-lf1-x132.google.com ([2a00:1450:4864:20::132]) by magus.postgresql.org with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.94.2) (envelope-from ) id 1sHq03-001Vso-MI for pgsql-hackers@postgresql.org; Thu, 13 Jun 2024 19:20:50 +0000 Received: by mail-lf1-x132.google.com with SMTP id 2adb3069b0e04-52c9034860dso1854033e87.2 for ; Thu, 13 Jun 2024 12:20:43 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1718306443; x=1718911243; darn=postgresql.org; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=sJMpmwoqXllgazcXs6G5MSv3V2w97mMgEMPRDIavxQA=; b=Iw+yXGsBsF7hE0wvtfT8ziItafPHp9cRztDpY8PUT4vTulTmc4uMYWN0lItmJgjJCu y0s2qLYmus7/Q1EU3800K37Aj3bXqzT4c7dtQyW3EznW4as3ZXt/bAc8laKALkkGpW/T FSftqPRHHfl8ALrh+FCaA1SBf+Z7Z87wfqKGAezbwkRb5fz/tQmubR+/Rlg0z0d+L1Nd MGg2rFejkmltJ1tHf8uSl8Mbuj1+x7PYGl9L8irh8Zzj8JfnJTGe/VgvT6esV+PUTmAT 0hWi3uHaqCMHh0MxPv3BCuHRMmn8LL0pnQEAuRnlUl6/tw0xp2mpHNPuZO77nRwxuc7O wVtg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718306443; x=1718911243; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=sJMpmwoqXllgazcXs6G5MSv3V2w97mMgEMPRDIavxQA=; b=YuP35UVtam5wfe9if6I8QuEKQj/2noqIpPD9UPAmZF7zgPvugyu51ChuyFvI4Bpqrc 6aQOstUCPpS4MFz8oJCxn7So4GxNY0l+y6uV/W5uEYvUELPEbMPUu2gIsFd95VQish5t hMs1oanh5BXBfJimu3WUC3du2EyAzuqdu2A+JcJ4V+cknBO9QtwYkYZjx8Z7WZneV+tl ksJRKKEHU+ouni+cFfYy/v+Erq5cFPEmR859hHfT60hXftc16ZrjXLihoFK2Ldk99NBX IX0OqHJmR8YTD5rg0ZSHPqSbodwJe4VuPo/MCzdfQxD/6BTMHMdC8oxDYb+cdNBeasBt 3PHg== X-Forwarded-Encrypted: i=1; AJvYcCWIIQ7gK14VCZeaTUE4Em3mseyPP1Xd9NvwKU414OLECYPAfUmSpQ5sdXuW7qgo/GvGWwqK/fWywOaezLALqeh6cdjQBj/vpO5dkjfV X-Gm-Message-State: AOJu0YxM+NBDM2eclEeVvII0P40pXhoPfG9dbXHLHJ/TQSZ5sr7fLP1N LhgmqUgrY0xp58PzzJO+64h1JHa93c2RZT8aQGRqrCJLfLsatRk8Sio4LXRQewcGgTHyWxNjRwH JzMGKA3hLHihHk5mODMMeQKnEJvVyb8mD X-Google-Smtp-Source: AGHT+IH2tgJwDZ3xHW617DA/O9fFwcXEdMYDHPu9tUuSvO5wPlfIJXo8M5izNL15xhKArLPRipAZWTkZ3j5S5VyHRs0= X-Received: by 2002:a19:e047:0:b0:52c:804e:e831 with SMTP id 2adb3069b0e04-52ca6e929edmr604716e87.47.1718306442622; Thu, 13 Jun 2024 12:20:42 -0700 (PDT) MIME-Version: 1.0 References: <20240610200411.byj6sv2vpgol6wcf@awork3.anarazel.de> <20240612155040.u6cvatdb5tiwcxci@awork3.anarazel.de> In-Reply-To: From: Robert Haas Date: Thu, 13 Jun 2024 15:20:29 -0400 Message-ID: Subject: Re: RFC: adding pytest as a supported test framework To: Jelte Fennema-Nio Cc: Daniel Gustafsson , Andres Freund , Jacob Champion , PostgreSQL Hackers Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Archived-At: Precedence: bulk On Thu, Jun 13, 2024 at 2:52=E2=80=AFPM Jelte Fennema-Nio wrote: > I understand and agree with your final stated goal of not ending up in > another big mess. It's also clear to me that you don't think the > current proposal achieves that goal. So I assume you have some > additional ideas for the proposal to help achieve that goal and/or > some specific worries that you'd like to get addressed better in the > proposal. But currently it's not really clear to me what either of > those are. Could you clarify? Hmm, I don't know that I have what you're hoping I have, or at least not any more than what I've said already. I interpreted Jacob's original email as articulating a goal ("For the v18 cycle, I would like to try to get pytest [1] in as a supported test driver, in addition to the current offerings") rather than a plan. There's no patch set yet and, as I understand it, no detailed plan for a patch set: that email seemed to focus on the question of desirability, rather than on outlining a plan of work, which I assume is still to come. Some things I'd like to see when a patch set does show up are: - good documentation for people who have no previous experience with Python and/or pytest e.g. here's how to set up your environment on Linux, Windows, macOS, *BSD so you can run the tests, here's how to run the tests, here's how it's different from the Perl framework we have now - no external dependencies on PostgreSQL connectors. psql or libpq foreign function interface. the latter would be a cool increment of progress over the status quo. - at least as much in-tree support for writing tests as we have today with PostgreSQL::Test::whatever, but not necessarily a 1:1 reinvention of the stuff we have now, and documentation of those facilities that is as good or, ideally, better than what we have today. - high overall code quality and level of maturity, not just something someone threw together for parity with the Perl system. - enough tests written for or converted to the new system to give reviewers confidence that it's truly usable and fit for purpose. The important thing to me here (as it so often is) is to think like a maintainer. Imagine that immediately after the patches for this feature are committed, the developers who did the work all disappear from the community and are never heard from again. How much pain does that end us causing? The answer doesn't need to be zero; that is unrealistic. But it also shouldn't be "well, if that happens we're going to have to rip the feature out" or "well, a bunch of committers who didn't want to write tests in Python in the first place are now going to have to do a lot of work in Python to stabilize the work already committed." --=20 Robert Haas EDB: http://www.enterprisedb.com