Re: [GRASS-SVN] r74358 - grass/trunk/lib/python/temporal

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Re: [GRASS-SVN] r74358 - grass/trunk/lib/python/temporal

Anna Petrášová
Hi,

it should really be >= 3 to avoid failing for future Python versions:


On Tue, Apr 9, 2019 at 5:07 AM <[hidden email]> wrote:
Author: sbl
Date: 2019-04-09 02:07:30 -0700 (Tue, 09 Apr 2019)
New Revision: 74358

Modified:
   grass/trunk/lib/python/temporal/datetime_math.py
   grass/trunk/lib/python/temporal/temporal_algebra.py
Log:
fix python version check

Modified: grass/trunk/lib/python/temporal/datetime_math.py
===================================================================
--- grass/trunk/lib/python/temporal/datetime_math.py    2019-04-08 19:50:21 UTC (rev 74357)
+++ grass/trunk/lib/python/temporal/datetime_math.py    2019-04-09 09:07:30 UTC (rev 74358)
@@ -19,7 +19,7 @@
 except:
     has_dateutil = False

-if sys.version_info[0]:
+if sys.version_info[0] == 3:
     unicode = str

 DAY_IN_SECONDS = 86400

Modified: grass/trunk/lib/python/temporal/temporal_algebra.py
===================================================================
--- grass/trunk/lib/python/temporal/temporal_algebra.py 2019-04-08 19:50:21 UTC (rev 74357)
+++ grass/trunk/lib/python/temporal/temporal_algebra.py 2019-04-09 09:07:30 UTC (rev 74358)
@@ -470,7 +470,7 @@
 from .datetime_math import create_time_suffix
 from .datetime_math import create_numeric_suffix

-if sys.version_info[0]:
+if sys.version_info[0] == 3:
     unicode = str

 ##############################################################################

_______________________________________________
grass-commit mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/grass-commit

_______________________________________________
grass-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/grass-dev
Reply | Threaded
Open this post in threaded view
|

Re: [GRASS-SVN] r74358 - grass/trunk/lib/python/temporal

Anna Petrášová
Documented here:

On Tue, Apr 9, 2019 at 10:34 PM Anna Petrášová <[hidden email]> wrote:
Hi,

it should really be >= 3 to avoid failing for future Python versions:


On Tue, Apr 9, 2019 at 5:07 AM <[hidden email]> wrote:
Author: sbl
Date: 2019-04-09 02:07:30 -0700 (Tue, 09 Apr 2019)
New Revision: 74358

Modified:
   grass/trunk/lib/python/temporal/datetime_math.py
   grass/trunk/lib/python/temporal/temporal_algebra.py
Log:
fix python version check

Modified: grass/trunk/lib/python/temporal/datetime_math.py
===================================================================
--- grass/trunk/lib/python/temporal/datetime_math.py    2019-04-08 19:50:21 UTC (rev 74357)
+++ grass/trunk/lib/python/temporal/datetime_math.py    2019-04-09 09:07:30 UTC (rev 74358)
@@ -19,7 +19,7 @@
 except:
     has_dateutil = False

-if sys.version_info[0]:
+if sys.version_info[0] == 3:
     unicode = str

 DAY_IN_SECONDS = 86400

Modified: grass/trunk/lib/python/temporal/temporal_algebra.py
===================================================================
--- grass/trunk/lib/python/temporal/temporal_algebra.py 2019-04-08 19:50:21 UTC (rev 74357)
+++ grass/trunk/lib/python/temporal/temporal_algebra.py 2019-04-09 09:07:30 UTC (rev 74358)
@@ -470,7 +470,7 @@
 from .datetime_math import create_time_suffix
 from .datetime_math import create_numeric_suffix

-if sys.version_info[0]:
+if sys.version_info[0] == 3:
     unicode = str

 ##############################################################################

_______________________________________________
grass-commit mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/grass-commit

_______________________________________________
grass-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/grass-dev
SBL
Reply | Threaded
Open this post in threaded view
|

Re: [GRASS-SVN] r74358 - grass/trunk/lib/python/temporal

SBL

Hi Anna and others,

 

Sorry for the mistake and thanks for the heads up! Good to see that experienced devs are on the watch!

Fixed in r74361

 

For the record, there is still:

lib/python/imaging/images2swf.py:87:PY3 = sys.version_info[0] == 3

which I did not touch.

 

Cheers

Stefan

 

From: grass-dev <[hidden email]> On Behalf Of Anna Petrášová
Sent: onsdag 10. april 2019 04:37
To: GRASS-dev <[hidden email]>
Cc: [hidden email]
Subject: Re: [GRASS-dev] [GRASS-SVN] r74358 - grass/trunk/lib/python/temporal

 

Documented here:

 

On Tue, Apr 9, 2019 at 10:34 PM Anna Petrášová <[hidden email]> wrote:

Hi,

 

it should really be >= 3 to avoid failing for future Python versions:

 

 

On Tue, Apr 9, 2019 at 5:07 AM <[hidden email]> wrote:

Author: sbl
Date: 2019-04-09 02:07:30 -0700 (Tue, 09 Apr 2019)
New Revision: 74358

Modified:
   grass/trunk/lib/python/temporal/datetime_math.py
   grass/trunk/lib/python/temporal/temporal_algebra.py
Log:
fix python version check

Modified: grass/trunk/lib/python/temporal/datetime_math.py
===================================================================
--- grass/trunk/lib/python/temporal/datetime_math.py    2019-04-08 19:50:21 UTC (rev 74357)
+++ grass/trunk/lib/python/temporal/datetime_math.py    2019-04-09 09:07:30 UTC (rev 74358)
@@ -19,7 +19,7 @@
 except:
     has_dateutil = False

-if sys.version_info[0]:
+if sys.version_info[0] == 3:
     unicode = str

 DAY_IN_SECONDS = 86400

Modified: grass/trunk/lib/python/temporal/temporal_algebra.py
===================================================================
--- grass/trunk/lib/python/temporal/temporal_algebra.py 2019-04-08 19:50:21 UTC (rev 74357)
+++ grass/trunk/lib/python/temporal/temporal_algebra.py 2019-04-09 09:07:30 UTC (rev 74358)
@@ -470,7 +470,7 @@
 from .datetime_math import create_time_suffix
 from .datetime_math import create_numeric_suffix

-if sys.version_info[0]:
+if sys.version_info[0] == 3:
     unicode = str

 ##############################################################################

_______________________________________________
grass-commit mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/grass-commit


_______________________________________________
grass-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/grass-dev