From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms0.migadu.com with LMTPS id wJSlHvYBqmDTbwEAgWs5BA (envelope-from ) for ; Sun, 23 May 2021 09:19:18 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id wBBWGvYBqmCaFgAAB5/wlQ (envelope-from ) for ; Sun, 23 May 2021 07:19:18 +0000 Received: from mail.notmuchmail.org (nmbug.tethera.net [IPv6:2607:5300:201:3100::1657]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id A9B5BB389 for ; Sun, 23 May 2021 09:19:17 +0200 (CEST) Received: from nmbug.tethera.net (localhost [127.0.0.1]) by mail.notmuchmail.org (Postfix) with ESMTP id A394F2AACE; Sun, 23 May 2021 03:19:10 -0400 (EDT) Received: from lahtoruutu.iki.fi (lahtoruutu.iki.fi [IPv6:2a0b:5c81:1c1::37]) by mail.notmuchmail.org (Postfix) with ESMTPS id 0E2D32AABE for ; Sun, 23 May 2021 03:19:08 -0400 (EDT) Received: from guru.guru-group.fi (unknown [IPv6:2a02:2380:1:9:5054:ff:feb7:a4bc]) (using TLSv1.2 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: too) by lahtoruutu.iki.fi (Postfix) with ESMTPSA id D40D51B000FD; Sun, 23 May 2021 10:19:02 +0300 (EEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; s=lahtoruutu; t=1621754342; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=ocU6mQamDSYG2WHNwoWQdcnxWrRAnQnkyvFcMuCvyl8=; b=WZeCabIg5EHEdwXVgNivU0wQG7p0CNx9hCtwBybtBm65gXLGUhr2K57wzaDXASzOfVuyAO BqcvoG3BE9XloH+Evqzhog0Oaq9FszcRHIJnDo6SsxO61Z2W3ucTGoCYIbXWewYGacdNvz OlkydegD3ffPaUjH/afDmK6cRqIs5cd4IyetidbEI9+RZKWdac+dgBV7N7xIKuUeSIR3NT Jf7RxnrXTyTV5YAa7w9eslAUlBs6WA18zHxVKk86SZFlYmN4O/4YBQlY2JK02TM+m814U7 xNK6E3o9Me2KKRNzeES7fLp42mS0RyUKOqH3K5H0QpQ1GH/Q8XOAZlKnL9Opfw== From: Tomi Ollila To: David Bremner , notmuch@notmuchmail.org Subject: Re: [PATCH] test: say_color() in one write(2) In-Reply-To: <87tumus8o9.fsf@tethera.net> References: <20210506141232.24182-1-tomi.ollila@iki.fi> <87tumus8o9.fsf@tethera.net> User-Agent: Notmuch/0.32+21~gfdddd4c (https://notmuchmail.org) Emacs/27.1 X-Face: HhBM'cA~ MIME-Version: 1.0 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=iki.fi; s=lahtoruutu; t=1621754342; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=ocU6mQamDSYG2WHNwoWQdcnxWrRAnQnkyvFcMuCvyl8=; b=vo42X+/mgwXnW3KZ+CVukCJ6sAmwXBI7rL09Tmv+voEV792M3L+N52eghcQJPmUwqBIfXE PwQg6RzSkCh6J4SBOiD77PP26FKohastR0+Llwah0GqF6wnVkqk6k+k4J4Cmyq4TKanc9p dNMuQszAEJg6DA3ZS+dl5EP4rXEnTSetM2yZQx/kHeweQTip/T1xURL0UP5QRsajHZwoUl n6hbZq5eF1OBL9oxvqhN/y3GGlut/FulF8Qnw1Q9ewUjta7Y13JMAwXokL3mKncCmPfSWI 1hvFEwEomQDWHpwT01w27XGo9qW0cdhECcdNScvlQNeD/g54CqcjBGxa15kV+g== ARC-Authentication-Results: i=1; ORIGINATING; auth=pass smtp.auth=too smtp.mailfrom=tomi.ollila@iki.fi ARC-Seal: i=1; s=lahtoruutu; d=iki.fi; t=1621754342; a=rsa-sha256; cv=none; b=RL9LUNtOgJiBW1L9tywfnDEHxTlZ0v+zs+tFXmKmU5n146t/FnkgCs7TzUx09Lm0ItoLfJ +jziMSv62+BP5NlMK7AVj59+13rKvSIK1iE+1wt/d/8K7U7CVfbtjW1z1IM83VUXj5bw7Z 0fap9Aq8xcWDal3fk8HBafdIMRjNPQktnUk91+SOFwXbIuRYN/M/LjfBrfOG9/8dw5MGAA 5Pf5XwVmTcOdVr8ddyVsQZ9D9ps43UF2R0BqbjWndZ6DN4/2RjcfxcSdry9Lyyzbqv1KZL 21u8/s01eSl22ePXW2CoLJfyHHYQAlhqq4hRP3VpwLQq/qsWc02GH1OG/Q+SAQ== Message-ID-Hash: U3X6EUJZDEBEGVGKSDNSNSY2MGOS7O67 X-Message-ID-Hash: U3X6EUJZDEBEGVGKSDNSNSY2MGOS7O67 X-MailFrom: tomi.ollila@iki.fi X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-notmuch.notmuchmail.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.2.1 Precedence: list List-Id: "Use and development of the notmuch mail system." List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1621754358; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=s8zCEXEqZdtPXDjaFB/LX1DWfxbPz93B6LGzhX7ZPe8=; b=A5oUYkT/KSWzGY3VBQn5Mka03rhJivt5Ss7YcurucbIvUdsjfGsoXUbifi8Pe7rZoTG84v eLwtNyxE5Mfv15OFhmckYLuxt3aG6A6liFPCLrZTc8IQ3WTONm3ChOuRjls34XWv1UXKfo ytPQq0JlCO70m+iUlh5XIb3jnoZg9tagLP0VYjKeZD3hP+CaXVm/Se549I0ZVqoWeqHAS3 PCQme6PoiZ/OkQMaKA5TFg1444IscGnsYhXLRvGLMw7bjC9tD+KiNDO2tMz1jnJ7e9T9eZ ls5k3dBDZ5SNqQuyBbS+l85b9rKp1ShPT1TPaxD+mfvYyLwSsNRZ1om03B0z4g== ARC-Seal: i=2; s=key1; d=yhetil.org; t=1621754358; a=rsa-sha256; cv=fail; b=QtYYAhKCi0AlvMDX78YPEjkeYBHLHMZH2LFSf8hgGFITURFKuftaLwRU5ozDwyhv6Hc+C9 OQxygSdDNN5VNJRbvlRUSwf0IQwxHLQueakBfffFuOeeJZPlCtbRc47hJRvNfpxG1HSOYM vv9fhVK/I9r94s+WgbAVYB1GX53QiZ8KIBX7dbYkqHAaQOAm9mv/Uxwzf2dwFrpV6mJSqg Y8Sgsx+ZLkBT5KSdZgc79bzM8AhA3PHeT2UNZ9Oq7s9nXiAK1UwBlS/F5wT7q1/Y1YbjEL +pjWCQ0dPyshgH5L5+qjUCC3+AfJwiiqJGWRDBCTEPIqbhSfXGpVqVdpwg2QdQ== ARC-Authentication-Results: i=2; aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=iki.fi header.s=lahtoruutu header.b=WZeCabIg; arc=reject ("signature check failed: fail, {[1] = sig:iki.fi:reject}"); dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 2607:5300:201:3100::1657 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Spam-Score: 0.93 Authentication-Results: aspmx1.migadu.com; dkim=fail ("body hash did not verify") header.d=iki.fi header.s=lahtoruutu header.b=WZeCabIg; arc=reject ("signature check failed: fail, {[1] = sig:iki.fi:reject}"); dmarc=none; spf=pass (aspmx1.migadu.com: domain of notmuch-bounces@notmuchmail.org designates 2607:5300:201:3100::1657 as permitted sender) smtp.mailfrom=notmuch-bounces@notmuchmail.org X-Migadu-Queue-Id: A9B5BB389 X-Spam-Score: 0.93 X-Migadu-Scanner: scn1.migadu.com X-TUID: rV5JenFTDbpE On Sat, May 22 2021, David Bremner wrote: > Tomi Ollila writes: > >> say_color() used to call (builtin) printf (and tput(1) to stdout) >> several times, which caused attempts to write messages with color >> to have partial content (e.g. escape sequences) often intermixed >> with other tests when parallel tests were run. > > I still see things like: > > T568-lib-thread: Testing API tests for notmuch_thread_* > PASS PASS count messages on closed db > get indexopts from closed database > > Is that expected? Both "PASS" are coloured OK. Yes, that is (unfortunately) possible, say_color only writes that PASS (with escape sequences coloring and reseting around it) (and subtest message if $debug is set). The messages following are written in separate lines, after say_color() returns (echo's if I remember correctly). Much more overhaul would be required to get the full line written in one write(1) -- I did think a few options when doing that change but nothing seems clear enough at this moment... Tomi