qwat / qwat-data-model

TEKSI Water module (project QWAT) - PostgreSQL / postgis Datamodel
https://www.teksi.ch
23 stars 24 forks source link

Standardize shebangs #222

Closed lbartoletti closed 6 years ago

lbartoletti commented 6 years ago

Like https://github.com/qgis/QGIS/pull/6229

Todo:

[x] Tests python2/python3? [x] Clean old python stuff? [x] Pep8

haubourg commented 6 years ago

If I get it well, your changes will require python3 by default ? It wasn't the case yet, except for PUM that recently introduced Python 3 dependency

lbartoletti commented 6 years ago

Yes. Some scripts are already with python3, travis run with python 3.5, so I thought there was a switch in progress. Since python3 is needed for PUM, potentially this can reduce dependencies to python2 (and remove from future from the scripts)

Otherwise, I modify the scripts but with python2 instead of python3 In all cases, in order to be really portable, you must specify the version of python used (/usr/bin/env python does not necessarily exist and can point to python2 or python3 depending on the linux distributions or other OS)

haubourg commented 6 years ago

ok good!

@sylvainbeo @3nids @elemoine @ponceta Do you agree for a complete and explicit switch to python3 in QWAT ? We'll need to add this in the README and doc too.

ponceta commented 6 years ago

This could be documented here too, as the python version was never defined and python2 was default.

Prerequisites should be set as link to the doc in the README.rst since there is an install section.

By the way, PostgreSQL (> 9.3) and PostGIS, the spatial extension (> 2.1) are historic prerequisites for qwat but tests are made with PostgreSQL 9.6 and Postgis 2.3.

sylvainbeo commented 6 years ago

Late, but yes. Source code is fully compatible.