From 093a9befa64626951099d2e13ba71c54d7bf77b3 Mon Sep 17 00:00:00 2001 From: rdimaio Date: Mon, 18 Mar 2024 17:09:55 +0100 Subject: [PATCH] Testing: Remove utf-8 declaration from add_header script; #6538 UTF-8 is the default source encoding in Python 3. Declaring it is unncessary, unless Python 2 is also supported. See also: - https://peps.python.org/pep-3120/ - https://docs.python.org/3/howto/unicode.html#python-s-unicode-support - https://stackoverflow.com/questions/14083111/should-i-use-encoding-declaration-in-python-3 --- tools/add_header | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tools/add_header b/tools/add_header index dee7661d24..f8abfc7d50 100755 --- a/tools/add_header +++ b/tools/add_header @@ -306,8 +306,7 @@ class PythonHeaderTemplate(HeaderTemplate): shebag_string = PythonHeaderTemplate._get_file_shebag(self.file_path) or "" return shebag_string \ - + """# -*- coding: utf-8 -*- -# Copyright European Organization for Nuclear Research (CERN) since 2012 + + """# Copyright European Organization for Nuclear Research (CERN) since 2012 # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License.