Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp572134ybb; Fri, 20 Mar 2020 04:25:29 -0700 (PDT) X-Google-Smtp-Source: ADFU+vtcyQrlsYbTVTZ9AxKBFzB2OUD5OdxzmiMNDlClCaPtd+BFpeI4JBgp7vDgUEA6KB++xVF9 X-Received: by 2002:a9d:4c8f:: with SMTP id m15mr6364177otf.273.1584703529226; Fri, 20 Mar 2020 04:25:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584703529; cv=none; d=google.com; s=arc-20160816; b=zC5qpK9r5B6G882+VMnAs148nOFwpLtijFxyliE3e/yoS1fiYD8m8nn/ayxAxxBNOM 576gifc4orn7EcHN7SkvYdrCGVjlsmt76lewN3AA6ZrT46TW3Ao9J5uel18NRmMensss RDiNPWBkXHzX1VOPOpwQrfJIgg5vnS6BwNJRbJDUnRhbNO/TkoExrFBoXQwEQx0T2UL6 ZcmClrK/qdSxIlY0OUz496zmCW89AyaYgF7SrsdWUgqJmbZmvWA4foodnUoC1YlA3t+A df5OrIRCsKpt8Wn1UrXnAj4CK/4y+tqaE+6bLASDnd3ugVMXbG5JRdowF2kK6LhYUjmc X8xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=L4wPJtn50I51+Mq1xXTEU9qAXC8zThyChF1UTylT4Ek=; b=Bww0tFKtq8lgJWu8lX+hThcYoGIo9/G6wsP6x6a2FoMhj8mqn6xTt9dzT4h7dHqFL2 Jbuf8KbM/v97GuuGAg9kje4oa0gEFuFjig5D2t+yxJEpEs99b5H2yuGGuQdcwdF+/IVk j9EuHCkESZMq4gEYOfGxrUYlMf/PgWfphORMuyhdcipVli9gxlI+T1n9FOQJ9y1jN+zm 9Ifne15zI+jM8l6piPOCBs44JeL0Tkvy2KexCRIyuoivEE4G6ALP8p5HDEa4os4LV79B l4QfZh4M9gXSClPC9cC/NCez8LT8N2VPvQ4omhJ/QUObCzMvTPKhUG2ullRFVyqjn0/E P3xQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kolabnow.com header.s=dkim20160331 header.b=VXkUZHjl; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id h203si2585787oif.3.2020.03.20.04.25.16; Fri, 20 Mar 2020 04:25:29 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kolabnow.com header.s=dkim20160331 header.b=VXkUZHjl; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727241AbgCTLYv (ORCPT + 99 others); Fri, 20 Mar 2020 07:24:51 -0400 Received: from mx.kolabnow.com ([95.128.36.42]:13690 "EHLO mx.kolabnow.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726820AbgCTLYv (ORCPT ); Fri, 20 Mar 2020 07:24:51 -0400 Received: from localhost (unknown [127.0.0.1]) by ext-mx-out003.mykolab.com (Postfix) with ESMTP id 8268C40D49; Fri, 20 Mar 2020 12:24:48 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kolabnow.com; h= content-type:content-type:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:date:subject:subject :from:from:received:received:received; s=dkim20160331; t= 1584703488; x=1586517889; bh=L4wPJtn50I51+Mq1xXTEU9qAXC8zThyChF1 UTylT4Ek=; b=VXkUZHjlkIg9lQ+dbJJk7fhtnrnjYZ1/w86vPvJxqb6wodOWjUX kMQHTrxi7FFv/hN4dmQTa4LeHQGqwIHfe4PhaX8MPEyFVnE046LFWsj7NX1PkRuX N4LWEGv9cF2ySkygQ6woBlK/SJZJ+rbDMs+Hhb6fVM3NJlgYRmbIACDpZojnB3w4 7MYLFBwsTF8lQ6YT5fTGf3Wn06+SeHSLzaEGvt+laCgFfHXM8ceUBFVoa4uFRvXx ErhTbA10xbOln6juYvX1ma4KpI8lqy4AvSgNOfz5VuG217iZoaGMPCNUh0qkVbw9 sA2Dq9TykTJKZwZwtaVLD/Jz2nNW6lDcEt197LaJnVxpLBnkwXHgJ20s+pukLM9l si++ZXQ+c0X+Thxd1p1Irlw8ZbY83td2dzVltngtGbBy+82z/jSYVmgjONS2Nrhm K3P6I0NdIY59Ot+pxWd+1x+k568aZfdO4Fplw3kZHAyLR5iAMM0HwYZLZJ5C9rFb CWk1eSCemF+OeZkPxhErCQi6PH+d+/TVToPnPtxGaFeqIG6STdLF3IxwVdVCjIKl GdpFg+XnlTF2K98eNVEPWBiCSrwZntCfCnr7mudL5hY9zd7ywD3J+uY8eGii6ety j5vMvuTwtejdEjovEATwmqDFp7DkRWBy4lp02VctVCU+OFHzKuiRed3E= X-Virus-Scanned: amavisd-new at mykolab.com X-Spam-Flag: NO X-Spam-Score: -1.9 X-Spam-Level: X-Spam-Status: No, score=-1.9 tagged_above=-10 required=5 tests=[BAYES_00=-1.9] autolearn=ham autolearn_force=no Received: from mx.kolabnow.com ([127.0.0.1]) by localhost (ext-mx-out003.mykolab.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id vEpvX-rmhzOR; Fri, 20 Mar 2020 12:24:48 +0100 (CET) Received: from int-mx002.mykolab.com (unknown [10.9.13.2]) by ext-mx-out003.mykolab.com (Postfix) with ESMTPS id 0A31140D30; Fri, 20 Mar 2020 12:24:46 +0100 (CET) Received: from ext-subm003.mykolab.com (unknown [10.9.6.3]) by int-mx002.mykolab.com (Postfix) with ESMTPS id 9F7256948; Fri, 20 Mar 2020 12:24:46 +0100 (CET) From: Federico Vaga To: Mauro Carvalho Chehab Cc: Linux Doc Mailing List , linux-kernel@vger.kernel.org, Jonathan Corbet Subject: Re: [PATCH] docs: conf.py: avoid thousands of duplicate label warning on Sphinx Date: Fri, 20 Mar 2020 12:24:45 +0100 Message-ID: <3508337.2CZTLhteCP@harkonnen> In-Reply-To: <16f1c270a9077032de379b1cb30dfbb3e3670aee.1584702515.git.mchehab+huawei@kernel.org> References: <20200320112122.48244ec4@coco.lan> <16f1c270a9077032de379b1cb30dfbb3e3670aee.1584702515.git.mchehab+huawei@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Friday, March 20, 2020 12:12:35 PM CET Mauro Carvalho Chehab wrote: > The autosectionlabel extension is nice, as it allows to refer to > a section by its name without requiring any extra tag to create > a reference name. > > However, on its default, it has two serious problems: > > 1) the namespace is global. So, two files with different > "introduction" section would create a label with the > same name. This is easily solvable by forcing the extension > to prepend the file name with: > > autosectionlabel_prefix_document = True > > 2) It doesn't work hierarchically. So, if there are two level 1 > sessions (let's say, one labeled "open" and another one "ioctl") > and both have a level 2 "synopsis" label, both section 2 will > have the same identical name. > > Currently, there's no way to tell Sphinx to create an > hierarchical reference like: > > open / synopsis > ioctl / synopsis > > This causes around 800 warnings. So, the fix should be to > not let autosectionlabel to produce references for anything > that it is not at level one, with: > > autosectionlabel_maxdepth = 1 So, for level 1 headers is fine to use autosectionlabel, but if we want to refer to level 2,3... we have to create labels manually. Fine with me