Description: adding a shebang with /usr/bin/python3 to example Python scripts
 we are shipping when they are meant to be executed.
Author: Pierre Gruet <pgt@debian.org>
Forwarded: xavier.warin@gmail.com
Last-Update: 2021-10-30

--- a/test/python/functional/testAmericanGlobalOption.py
+++ b/test/python/functional/testAmericanGlobalOption.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testAmericanOption.py
+++ b/test/python/functional/testAmericanOption.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testAmericanOptionForSparse.py
+++ b/test/python/functional/testAmericanOptionForSparse.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testAmericanOptionKernel.py
+++ b/test/python/functional/testAmericanOptionKernel.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2017 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testAmericanOptionTree.py
+++ b/test/python/functional/testAmericanOptionTree.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2019 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testDemandSDDP.py
+++ b/test/python/functional/testDemandSDDP.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorage.py
+++ b/test/python/functional/testGasStorage.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorageHighLevel.py
+++ b/test/python/functional/testGasStorageHighLevel.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorageHighLevelMpi.py
+++ b/test/python/functional/testGasStorageHighLevelMpi.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorageKernel.py
+++ b/test/python/functional/testGasStorageKernel.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorageSwitchCost.py
+++ b/test/python/functional/testGasStorageSwitchCost.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorageSwitchCostHighLevel.py
+++ b/test/python/functional/testGasStorageSwitchCostHighLevel.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorageSwitchCostHighLevelMpi.py
+++ b/test/python/functional/testGasStorageSwitchCostHighLevelMpi.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorageTreeHighLevel.py
+++ b/test/python/functional/testGasStorageTreeHighLevel.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2019 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testGasStorageVaryingCavity.py
+++ b/test/python/functional/testGasStorageVaryingCavity.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testLake.py
+++ b/test/python/functional/testLake.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testLakeHighLevel.py
+++ b/test/python/functional/testLakeHighLevel.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testMicrogrid.py
+++ b/test/python/functional/testMicrogrid.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 
 # Copyright (C) 2018 The Regents of the University of California, Michael Ludkovski and Aditya Maheshwari
 # All Rights Reserved
--- a/test/python/functional/testMicrogridDEA.py
+++ b/test/python/functional/testMicrogridDEA.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2018 The Regents of the University of California, Michael Ludkovski and Aditya Maheshwari
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testSwingOptimSimuHighLevel.py
+++ b/test/python/functional/testSwingOptimSimuHighLevel.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testSwingOptimSimuHighLevelMpi.py
+++ b/test/python/functional/testSwingOptimSimuHighLevelMpi.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testSwingOptimSimuND.py
+++ b/test/python/functional/testSwingOptimSimuND.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testSwingOptimSimuNDHighLevelMpi.py
+++ b/test/python/functional/testSwingOptimSimuNDHighLevelMpi.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testSwingOptionMpi.py
+++ b/test/python/functional/testSwingOptionMpi.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/functional/testThermalAssetHighLevel.py
+++ b/test/python/functional/testThermalAssetHighLevel.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2021 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/cdf/testFastCDF.py
+++ b/test/python/unit/cdf/testFastCDF.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2020 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/cdf/testFastCDFOnSample.py
+++ b/test/python/unit/cdf/testFastCDFOnSample.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2020 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/continuation/testContinuation.py
+++ b/test/python/unit/continuation/testContinuation.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/continuation/testContinuationCut.py
+++ b/test/python/unit/continuation/testContinuationCut.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/geners/testBinaryArchive.py
+++ b/test/python/unit/geners/testBinaryArchive.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/geners/testSomeBinaryArchiveStorage.py
+++ b/test/python/unit/geners/testSomeBinaryArchiveStorage.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2017 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/global/testGlobal.py
+++ b/test/python/unit/global/testGlobal.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/global/testGlobalMpi.py
+++ b/test/python/unit/global/testGlobalMpi.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/global/testMeanRevertingAndGas.py
+++ b/test/python/unit/global/testMeanRevertingAndGas.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/grids/testGrids.py
+++ b/test/python/unit/grids/testGrids.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2017 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/grids/testLegendreGrid.py
+++ b/test/python/unit/grids/testLegendreGrid.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/grids/testRegularGrids.py
+++ b/test/python/unit/grids/testRegularGrids.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/grids/testSparseGrids.py
+++ b/test/python/unit/grids/testSparseGrids.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testGetMesh.py
+++ b/test/python/unit/regression/testGetMesh.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testGlobalRegression.py
+++ b/test/python/unit/regression/testGlobalRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2017 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testGridKernelRegression.py
+++ b/test/python/unit/regression/testGridKernelRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2017 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testLaplacianGridKernelRegression.py
+++ b/test/python/unit/regression/testLaplacianGridKernelRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2020 EDF
 # Copyright (C) 2020 CSIRO Data61
 # All Rights Reserved
--- a/test/python/unit/regression/testLaplacianKernelRegression.py
+++ b/test/python/unit/regression/testLaplacianKernelRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2017 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testLocalConstDiscrLastDimRegression.py
+++ b/test/python/unit/regression/testLocalConstDiscrLastDimRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2021 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testLocalConstRegression.py
+++ b/test/python/unit/regression/testLocalConstRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testLocalKMeansRegression.py
+++ b/test/python/unit/regression/testLocalKMeansRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2019 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testLocalLinearDiscrLastDimRegression.py
+++ b/test/python/unit/regression/testLocalLinearDiscrLastDimRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2021 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testLocalLinearRegression.py
+++ b/test/python/unit/regression/testLocalLinearRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testLocalSameSizeConstRegression.py
+++ b/test/python/unit/regression/testLocalSameSizeConstRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testLocalSameSizeLinearRegression.py
+++ b/test/python/unit/regression/testLocalSameSizeLinearRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/regression/testSparseRegression.py
+++ b/test/python/unit/regression/testSparseRegression.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/sddp/testSDDPUnitTest.py
+++ b/test/python/unit/sddp/testSDDPUnitTest.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2016 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
--- a/test/python/unit/tree/testTree.py
+++ b/test/python/unit/tree/testTree.py
@@ -1,3 +1,5 @@
+#!/usr/bin/python3
+
 # Copyright (C) 2019 EDF
 # All Rights Reserved
 # This code is published under the GNU Lesser General Public License (GNU LGPL)
