[GRASS-SVN] r71393 - grass/trunk/lib/init

svn_grass at osgeo.org svn_grass at osgeo.org
Fri Aug 11 12:33:52 PDT 2017


Author: wenzeslaus
Date: 2017-08-11 12:33:51 -0700 (Fri, 11 Aug 2017)
New Revision: 71393

Modified:
   grass/trunk/lib/init/grass.py
Log:
init: use the Python 3 compatible string type

Modified: grass/trunk/lib/init/grass.py
===================================================================
--- grass/trunk/lib/init/grass.py	2017-08-11 15:03:53 UTC (rev 71392)
+++ grass/trunk/lib/init/grass.py	2017-08-11 19:33:51 UTC (rev 71393)
@@ -1373,10 +1373,10 @@
     :param batch_job: executable and parameters in a list or a string
     """
     batch_job_string = batch_job
-    if not isinstance(batch_job, basestring):
+    if not isinstance(batch_job, string_types):
         batch_job_string = ' '.join(batch_job)
     message(_("Executing <%s> ...") % batch_job_string)
-    if isinstance(batch_job, basestring):
+    if isinstance(batch_job, string_types):
         proc = Popen(batch_job, shell=True)
     else:
         try:



More information about the grass-commit mailing list