From mboxrd@z Thu Jan 1 00:00:00 1970
Return-Path:
Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29])
by sourceware.org (Postfix) with ESMTPS id 7A7D3385116B
for ; Thu, 13 Oct 2022 09:37:49 +0000 (GMT)
DMARC-Filter: OpenDMARC Filter v1.4.1 sourceware.org 7A7D3385116B
Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=suse.cz
Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=suse.cz
Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512)
(No client certificate requested)
by smtp-out2.suse.de (Postfix) with ESMTPS id 4A2821F385;
Thu, 13 Oct 2022 09:37:48 +0000 (UTC)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa;
t=1665653868; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc:
mime-version:mime-version:content-type:content-type:
content-transfer-encoding:content-transfer-encoding;
bh=KKEHhnnGaKyS60rWGbmf+yPqMwS8XxLnFNs3nNBzHP0=;
b=Gf014oPU/Jf0MXV45map4fXtvPMdL6OId7gKCfRp+gVtCqqROnPHXSE1feEkOiILOsAWKX
0C1z/iL1CFBwXnWS65Xlf03q3B+O2tYh82nx0iPY57fey+acjGTzv/mTPFL8Z13md1qSBl
ZmN5uUfYz0+nm6F6u9VGnSeRpv267Kc=
DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz;
s=susede2_ed25519; t=1665653868;
h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc:
mime-version:mime-version:content-type:content-type:
content-transfer-encoding:content-transfer-encoding;
bh=KKEHhnnGaKyS60rWGbmf+yPqMwS8XxLnFNs3nNBzHP0=;
b=oTkMReSCjDdjQF1GHEpSaZO6W31D/Jl75SoY4I/dxbQ373tBveQ93S+9n1omE07c8dRSRS
ylIVFO16s8vFb6BQ==
Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74])
(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512)
(No client certificate requested)
by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id 17DB8139F3;
Thu, 13 Oct 2022 09:37:48 +0000 (UTC)
Received: from dovecot-director2.suse.de ([192.168.254.65])
by imap2.suse-dmz.suse.de with ESMTPSA
id yNuXBGzcR2N+FgAAMHmgww
(envelope-from ); Thu, 13 Oct 2022 09:37:48 +0000
Message-ID:
Date: Thu, 13 Oct 2022 11:37:47 +0200
MIME-Version: 1.0
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101
Thunderbird/102.3.1
From: =?UTF-8?Q?Martin_Li=c5=a1ka?=
Subject: [DOCS] Python Language Conventions
To: gcc-patches@gcc.gnu.org
Content-Language: en-US
Cc: Gerald Pfeifer , Gaius Mulley ,
David Malcolm
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Spam-Status: No, score=-12.0 required=5.0 tests=BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,GIT_PATCH_0,SPF_HELO_NONE,SPF_PASS,TXREP autolearn=ham autolearn_force=no version=3.4.6
X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org
List-Id:
I think we should add how Python scripts should be formatted. I noticed
that while reading the Modula-2 patchset where it follows the C/C++ style
when it comes to Python files.
Ready to be installed?
Thanks,
Martin
---
htdocs/codingconventions.html | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/htdocs/codingconventions.html b/htdocs/codingconventions.html
index e4d30510..180ef35a 100644
--- a/htdocs/codingconventions.html
+++ b/htdocs/codingconventions.html
@@ -80,6 +80,7 @@ the conventions separately from any other changes to the code.
+Python Language Conventions
@@ -1483,6 +1484,19 @@ with a right brace, optional closing comment, and a new line.
Definitions within the body of a namespace are not indented.
+Python Language Conventions
+
+
+Python scripts should follow PEP 8 – Style Guide for Python Code
+which can be verified by flake8 tool.
+We do also recommend using the following flake8
plug-ins:
+
+
+ - flake8-builtins
+ - flake8-import-order
+ - flake8-quotes
+
+