Newsgroups: php.internals Path: news.php.net Xref: news.php.net php.internals:116145 Return-Path: Delivered-To: mailing list internals@lists.php.net Received: (qmail 65078 invoked from network); 23 Sep 2021 13:29:33 -0000 Received: from unknown (HELO php-smtp4.php.net) (45.112.84.5) by pb1.pair.com with SMTP; 23 Sep 2021 13:29:33 -0000 Received: from php-smtp4.php.net (localhost [127.0.0.1]) by php-smtp4.php.net (Postfix) with ESMTP id 74B681804C5 for ; Thu, 23 Sep 2021 07:11:00 -0700 (PDT) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on php-smtp4.php.net X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM,HTML_MESSAGE, RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=no autolearn_force=no version=3.4.2 X-Spam-ASN: AS15169 209.85.128.0/17 X-Spam-Virus: No X-Envelope-From: Received: from mail-ed1-f49.google.com (mail-ed1-f49.google.com [209.85.208.49]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by php-smtp4.php.net (Postfix) with ESMTPS for ; Thu, 23 Sep 2021 07:11:00 -0700 (PDT) Received: by mail-ed1-f49.google.com with SMTP id y89so13464677ede.2 for ; Thu, 23 Sep 2021 07:11:00 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=s/uVI1m3ABk4yoSpPLMfONdGaTfZ2FjgZ/zJSN+RpY4=; b=gTjkJt/yMc7oAMqrxuhzNGdM6NYQufHqxGMNPh6eigQ55k1J5j3bVsfH6OdMohaHt0 JBm2MqJJ8cvbfnjkltyGPSrBrg3v9hr5m6nvdjb3O+pFBTkJw9ZPdQYzYHwmDfvybPgK qPo90SffNkscC/MyAImbDPaGZzvEV56DHVDNaZX2vddHqAGywmyak3U0z2E4UyzNsrPf YHwz2Z+lxwremg10/bI9se8ZiVZt1EBbWg5sfz9MQ+PO2rR/tTdRR/2MkAAE16DdAChP Vzrn2JTfJY8JRmgti7rYolMFlRDbFSlbZSrjWbjdPL0eQIpj4EEbvJMm7Nfo/NpWRqdP /R5w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=s/uVI1m3ABk4yoSpPLMfONdGaTfZ2FjgZ/zJSN+RpY4=; b=NuSt3b8EduNs0kAvvSFhMdn0b4p1BO7pAi9ZsqtBbXBVR03u+V2W8dWoDK2ziNsqwX 9TTPhbjX8Rc0R+cpOaNVuYzc8STg83vEHQ3SdtvFWZqmIrCyK6nQbqiTjC0RSErHYfq2 SRjDSxevV3tfdA26+RrZr/ko1ueDJ7WmMXcsAfep9kJ7KE0gxTCiofJZBy2Yf+iE28X3 CoFqy1O0+ZRsIkhUBFMdjmZqTH3lE+4ejo9XPTYRFBZ87t7hPyCwVmUpabbh8xBjw/Vx qDIT6J9WSfnjj7gG1IRTAreGA+G26Tx6R8DVXPos2lAGVh+1ujVEmFMamPUn3WqoUxxR mu3g== X-Gm-Message-State: AOAM530A/YwzWuNwRB+iCU0PrDsq10OmiUAeJTbyYrLUeEKN2rXFohkx vGvDAs8Kl5J049EMK7v3pRz+CtuaPNT76DywAX7o4ho4 X-Google-Smtp-Source: ABdhPJyGY+R2KJTJQlnPELTQ5ekylbST8EUOo+dVZtdZzg1Aej4l3K5iHyswnZ2g+KnybnFs5JXqxlyB2hNAEP9O4Ds= X-Received: by 2002:a17:906:fc09:: with SMTP id ov9mr5228200ejb.128.1632406257127; Thu, 23 Sep 2021 07:10:57 -0700 (PDT) MIME-Version: 1.0 References: In-Reply-To: Date: Thu, 23 Sep 2021 16:10:39 +0200 Message-ID: To: Jeremy Mikola Cc: PHP Internals Content-Type: multipart/alternative; boundary="00000000000015d49905ccaa33d0" Subject: Re: [PHP-DEV] run-tests SKIPIF caching can be problematic for third-party extensions From: nikita.ppv@gmail.com (Nikita Popov) --00000000000015d49905ccaa33d0 Content-Type: text/plain; charset="UTF-8" On Wed, Sep 15, 2021 at 7:23 PM Jeremy Mikola wrote: > I just discovered that run-tests.php was changed to cache SKIPIF evaluation > since 8.1.0beta3[1]. I believe ext-mongodb ran into the same issue as > mysqli[2], as we use SKIPIF to check that database contents are clean going > into a test. The present solution in core is to check SKIPIF output for > "nocache" [3,4] and allow individual tests to opt out of caching; however, > I'm worried that won't be portable for third-party extensions, where we > test with run-tests.php for each version of PHP that we support. > > Is there still time to consider an alternative solution? If "nocache" needs > to remain in place for mysqli, perhaps 8.1.0's run-tests.php can be > enhanced to consult an environment variable (for maximum BC and playing > nice with `make test`) that disables caching entirely. > I'm not sure I understand the setup you're using. The "nocache" tag that mysqli uses covers the situation where part of the test setup is done in the SKIPIF section -- because checking whether the test should be skipped requires doing the same setup as the actual test. If the test does get skipped, it's still fine to cache that. Now, it sounds like your situation is different from that, and you actually have SKIPIF sections where first one test should be skipped, but then a later test with identical SKIPIF shouldn't be skipped. Is that correct? What changes between the time these two tests run? Regards, Nikita --00000000000015d49905ccaa33d0--