From e742d451fe59ac8869fa425481dca86f905dbe15 Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Thu, 30 Jan 2020 09:59:30 +0100 Subject: [PATCH 01/11] update travis and appveyor config file --- appveyor.yml | 2 +- travis.yml | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 4a05c293..26fab5b9 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -6,7 +6,7 @@ environment: matrix: # Add here environement variables to control the Travis CI build - CONDA_RECIPE: conda - CONDA_VERSION: 2 + CONDA_VERSION: 3 install: - git clone https://github.com/OpenAlea/appveyor-ci.git appveyor-ci diff --git a/travis.yml b/travis.yml index 88e85d3c..0e6bd29e 100644 --- a/travis.yml +++ b/travis.yml @@ -25,8 +25,6 @@ before_script: script: - source script.sh - - conda install nose - - cd test; nosetests -v after_success: - source after_success.sh From 4dbd62e2f47cf034a0728f173c94fbf2d665fb83 Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Fri, 31 Jan 2020 23:29:17 +0100 Subject: [PATCH 02/11] fix bug for windows --- conda/meta.yaml | 2 +- src/cpp/axialtree.cpp | 2 +- src/cpp/lpy_python.cpp | 66 ----------------------------- src/cpp/lpy_python.h | 57 ------------------------- src/cpp/module.cpp | 2 +- src/openalea/lpy/gui/generate_ui.py | 35 +++++++-------- src/openalea/lpy/gui/lpydock.py | 13 +++--- src/openalea/lpy/gui/lpyshell.py | 4 ++ 8 files changed, 29 insertions(+), 152 deletions(-) delete mode 100644 src/cpp/lpy_python.cpp delete mode 100644 src/cpp/lpy_python.h diff --git a/conda/meta.yaml b/conda/meta.yaml index b74fda79..fe9d4e65 100644 --- a/conda/meta.yaml +++ b/conda/meta.yaml @@ -15,7 +15,7 @@ about: build: preserve_egg_dir: True - number: 3 + number: 4 requirements: build: - binutils_impl_linux-64<2.31.0 # [linux] diff --git a/src/cpp/axialtree.cpp b/src/cpp/axialtree.cpp index 209d749b..88602b6a 100644 --- a/src/cpp/axialtree.cpp +++ b/src/cpp/axialtree.cpp @@ -33,7 +33,7 @@ #include "lpy_parser.h" #include "tracker.h" #include "matching.h" -#include "lpy_python.h" +#include using namespace boost::python; diff --git a/src/cpp/lpy_python.cpp b/src/cpp/lpy_python.cpp deleted file mode 100644 index c6cf9478..00000000 --- a/src/cpp/lpy_python.cpp +++ /dev/null @@ -1,66 +0,0 @@ -/* --------------------------------------------------------------------------- - # - # L-Py: L-systems in Python - # - # Copyright 2003-2008 UMR Cirad/Inria/Inra Dap - Virtual Plant Team - # - # File author(s): F. Boudon (frederic.boudon@cirad.fr) - # - # --------------------------------------------------------------------------- - # - # GNU General Public Licence - # - # This program is free software; you can redistribute it and/or - # modify it under the terms of the GNU General Public License as - # published by the Free Software Foundation; either version 2 of - # the License, or (at your option) any later version. - # - # This program is distributed in the hope that it will be useful, - # but WITHOUT ANY WARRANTY; without even the implied warranty of - # MERCHANTABILITY or FITNESS For A PARTICULAR PURPOSE. See the - # GNU General Public License for more details. - # - # You should have received a copy of the GNU General Public - # License along with this program; see the file COPYING. If not, - # write to the Free Software Foundation, Inc., 59 - # Temple Place - Suite 330, Boston, MA 02111-1307, USA. - # - # --------------------------------------------------------------------------- - */ - - -#include "lpy_python.h" - -/*---------------------------------------------------------------------------*/ - -PySeqIterator::PySeqIterator(boost::python::object seq) : - __iter_obj( ), __valid(true) -{ - PyObject * pyiter = PyObject_GetIter( seq.ptr() ) ; - __valid = (pyiter != NULL); - __iter_obj = boost::python::object(boost::python::handle<>( pyiter ) ); - _next(); -} - -bool PySeqIterator::is_valid() const { return __valid;} - -boost::python::object PySeqIterator::next() -{ - boost::python::object result = __next_obj; - _next(); - return result; - -} - -void PySeqIterator::_next() -{ - if (__valid) { - PyObject * item = PyIter_Next(__iter_obj.ptr()); - __valid = (item != NULL); - if (__valid) - __next_obj = boost::python::object( boost::python::handle(item)); - else - __next_obj = boost::python::object(); - } -} - diff --git a/src/cpp/lpy_python.h b/src/cpp/lpy_python.h deleted file mode 100644 index fbe6160f..00000000 --- a/src/cpp/lpy_python.h +++ /dev/null @@ -1,57 +0,0 @@ -/* --------------------------------------------------------------------------- - # - # L-Py: L-systems in Python - # - # Copyright 2003-2008 UMR Cirad/Inria/Inra Dap - Virtual Plant Team - # - # File author(s): F. Boudon (frederic.boudon@cirad.fr) - # - # --------------------------------------------------------------------------- - # - # GNU General Public Licence - # - # This program is free software; you can redistribute it and/or - # modify it under the terms of the GNU General Public License as - # published by the Free Software Foundation; either version 2 of - # the License, or (at your option) any later version. - # - # This program is distributed in the hope that it will be useful, - # but WITHOUT ANY WARRANTY; without even the implied warranty of - # MERCHANTABILITY or FITNESS For A PARTICULAR PURPOSE. See the - # GNU General Public License for more details. - # - # You should have received a copy of the GNU General Public - # License along with this program; see the file COPYING. If not, - # write to the Free Software Foundation, Inc., 59 - # Temple Place - Suite 330, Boston, MA 02111-1307, USA. - # - # --------------------------------------------------------------------------- - */ - -#ifndef __lpy_python_h__ -#define __lpy_python_h__ - -#include "lpy_config.h" -#include - -/*---------------------------------------------------------------------------*/ - - -class PySeqIterator { -public: - PySeqIterator(boost::python::object seq) ; - - bool is_valid() const ; - - boost::python::object next() ; - -protected: - void _next() ; - - boost::python::object __iter_obj; - boost::python::object __next_obj; - bool __valid; - -}; - -#endif \ No newline at end of file diff --git a/src/cpp/module.cpp b/src/cpp/module.cpp index 772da66d..794a5f50 100644 --- a/src/cpp/module.cpp +++ b/src/cpp/module.cpp @@ -33,12 +33,12 @@ #include "patternmodule.h" #include "matching.h" #include "lsyscontext.h" -#include "lpy_python.h" #include "lpy_parser.h" #include "tracker.h" #include "packedargs.h" #include #include +#include using namespace boost::python; LPY_USING_NAMESPACE diff --git a/src/openalea/lpy/gui/generate_ui.py b/src/openalea/lpy/gui/generate_ui.py index 54488968..2dab7380 100644 --- a/src/openalea/lpy/gui/generate_ui.py +++ b/src/openalea/lpy/gui/generate_ui.py @@ -1,26 +1,21 @@ # Generate GUI if necessary -try: - import openalea.lpy.gui.py2exe_release - py2exe_release = True -except: - py2exe_release = False +from os.path import dirname, exists, join +ldir = dirname(__file__) +release = exists(join(ldir,'py2exe_release.py')) -if not py2exe_release: - import compile_ui as ui -# from . import compile_ui as ui +if not release: print("Generate Ui - imported") - import os.path - ldir = os.path.dirname(__file__) + from . import compile_ui as ui print("Generate Ui") - ui.check_ui_generation(os.path.join(ldir, 'lpymainwindow.ui')) - ui.check_ui_generation(os.path.join(ldir, 'debugger_ui.ui')) - ui.check_ui_generation(os.path.join(ldir, 'debugger_right_ui.ui')) - ui.check_ui_generation(os.path.join(ldir, 'logindialog.ui')) - ui.check_ui_generation(os.path.join(ldir, 'logdialog.ui')) - ui.check_rc_generation(os.path.join(ldir, 'lpyresources.qrc')) - ui.check_ui_generation(os.path.join(ldir, 'killsimulationwidget.ui')) - ui.check_ui_generation(os.path.join(ldir, 'lpyprefwidget.ui')) - ui.check_ui_generation(os.path.join(ldir, 'scalarmetaedit.ui')) - ui.check_ui_generation(os.path.join(ldir, 'scalarfloatmetaedit.ui')) + ui.check_rc_generation(join(ldir, 'lpyresources.qrc')) + ui.check_ui_generation(join(ldir, 'lpymainwindow.ui')) + ui.check_ui_generation(join(ldir, 'debugger_ui.ui')) + ui.check_ui_generation(join(ldir, 'debugger_right_ui.ui')) + ui.check_ui_generation(join(ldir, 'logindialog.ui')) + ui.check_ui_generation(join(ldir, 'logdialog.ui')) + ui.check_ui_generation(join(ldir, 'killsimulationwidget.ui')) + ui.check_ui_generation(join(ldir, 'lpyprefwidget.ui')) + ui.check_ui_generation(join(ldir, 'scalarmetaedit.ui')) + ui.check_ui_generation(join(ldir, 'scalarfloatmetaedit.ui')) del ldir pass diff --git a/src/openalea/lpy/gui/lpydock.py b/src/openalea/lpy/gui/lpydock.py index 2cb35961..5b5e7feb 100644 --- a/src/openalea/lpy/gui/lpydock.py +++ b/src/openalea/lpy/gui/lpydock.py @@ -79,12 +79,12 @@ def initDocks(lpywidget): lpywidget.profilerDock.hide() #interpreter dock if lpywidget.withinterpreter : - try: - set_shell_widget(lpywidget) - except: - lpywidget.withinterpreter = False - lpywidget.interpreter = None - lpywidget.interpreterDock.hide() + #try: + set_shell_widget(lpywidget) + #except: + # lpywidget.withinterpreter = False + # lpywidget.interpreter = None + # lpywidget.interpreterDock.hide() if lpywidget.withinterpreter: action = lpywidget.interpreterDock.toggleViewAction() @@ -98,6 +98,7 @@ def initDocks(lpywidget): lpywidget.interpreter = None def initShell(lpywidget): + return lpywidget.interpreter.locals['window'] = lpywidget lpywidget.shell.run_code('from openalea.plantgl.all import *') lpywidget.shell.run_code('from openalea.lpy import *') diff --git a/src/openalea/lpy/gui/lpyshell.py b/src/openalea/lpy/gui/lpyshell.py index adbffec0..31f14671 100644 --- a/src/openalea/lpy/gui/lpyshell.py +++ b/src/openalea/lpy/gui/lpyshell.py @@ -3,6 +3,7 @@ from qtconsole.rich_jupyter_widget import RichJupyterWidget from qtconsole.inprocess import QtInProcessKernelManager # from .streamredirection import GraphicalStreamRedirection +import sys, tempfile class LpyShellWidget(RichJupyterWidget): #, GraphicalStreamRedirection): @@ -12,6 +13,9 @@ def __init__(self, parent=None): If no parent widget has been specified, it is possible to exit the interpreter by Ctrl-D. """ + if sys.executable.endswith('pythonw.exe'): + sys.stdout = open(tempfile.gettempdir() + '/lpystdout.txt', 'w') + sys.stderr = open(tempfile.gettempdir() + '/lpystderr.txt', 'w') RichJupyterWidget.__init__(self, parent) From fa0f3c365686f5aded375fc6f0f22f4681a86c4e Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Sun, 2 Feb 2020 18:08:37 +0100 Subject: [PATCH 03/11] remove print that create bug in deployment --- setup.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/setup.py b/setup.py index f37fdce9..67987f51 100644 --- a/setup.py +++ b/setup.py @@ -33,7 +33,7 @@ exec(fp.read(), versioninfo) version= versioninfo['LPY_VERSION_STR'] -print (pkg_name+': version = '+version) +#print (pkg_name+': version = '+version) # cmake build directory From ac74d0546f7cd8ddfc579e285bc1ea76ab26d27f Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Sun, 2 Feb 2020 18:32:23 +0100 Subject: [PATCH 04/11] add share data. fix bug with ui generation --- conda/build.sh | 2 ++ conda/meta.yaml | 2 +- src/openalea/lpy/gui/generate_ui.py | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/conda/build.sh b/conda/build.sh index af75983a..36892c17 100644 --- a/conda/build.sh +++ b/conda/build.sh @@ -57,6 +57,8 @@ echo "PYTHON:" ${PYTHON} #export PYTHONPATH=${PREFIX}/lib/python${PY_VER}/site-packages/ ${PYTHON} setup.py install --prefix=${PREFIX} +cp -r share `python -c "import os, openalea.lpy as lpy ; print(os.path.dirname(lpy.__file__))"`/.. + echo echo "****** CHECK PYTHON LIB" diff --git a/conda/meta.yaml b/conda/meta.yaml index fe9d4e65..a4f1abb4 100644 --- a/conda/meta.yaml +++ b/conda/meta.yaml @@ -15,7 +15,7 @@ about: build: preserve_egg_dir: True - number: 4 + number: 5 requirements: build: - binutils_impl_linux-64<2.31.0 # [linux] diff --git a/src/openalea/lpy/gui/generate_ui.py b/src/openalea/lpy/gui/generate_ui.py index 2dab7380..918324f9 100644 --- a/src/openalea/lpy/gui/generate_ui.py +++ b/src/openalea/lpy/gui/generate_ui.py @@ -5,7 +5,7 @@ if not release: print("Generate Ui - imported") - from . import compile_ui as ui + import compile_ui as ui print("Generate Ui") ui.check_rc_generation(join(ldir, 'lpyresources.qrc')) ui.check_ui_generation(join(ldir, 'lpymainwindow.ui')) From 21afbdd2fe977e61bc39719c2a58ad691cbec226 Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Sun, 2 Feb 2020 18:59:12 +0100 Subject: [PATCH 05/11] Update build.sh --- conda/build.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/conda/build.sh b/conda/build.sh index 36892c17..f8fe69bb 100644 --- a/conda/build.sh +++ b/conda/build.sh @@ -57,7 +57,7 @@ echo "PYTHON:" ${PYTHON} #export PYTHONPATH=${PREFIX}/lib/python${PY_VER}/site-packages/ ${PYTHON} setup.py install --prefix=${PREFIX} -cp -r share `python -c "import os, openalea.lpy as lpy ; print(os.path.dirname(lpy.__file__))"`/.. +cp -r share `${PYTHON} -c "import os, openalea.lpy as lpy ; print(os.path.dirname(lpy.__file__))"`/.. echo echo "****** CHECK PYTHON LIB" From 3ff8b513a000bfd4d41534b5661b0badb6c6d9f7 Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Sun, 2 Feb 2020 20:21:31 +0100 Subject: [PATCH 06/11] fix py3 syntax on share code --- share/extension/mtgaxiom/evalrange.py | 2 +- share/extension/mtgaxiom/mtgcompare.py | 2 +- share/extension/mtgaxiom/mtgimport.py | 2 +- share/tutorial/lpy-paper12-examples/code2.py | 2 +- share/tutorial/lpy-paper12-examples/code4.py | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/share/extension/mtgaxiom/evalrange.py b/share/extension/mtgaxiom/evalrange.py index 2544c5ad..b3942268 100644 --- a/share/extension/mtgaxiom/evalrange.py +++ b/share/extension/mtgaxiom/evalrange.py @@ -52,7 +52,7 @@ def plotresult(i=0, j=101,step = 1): for i,v in enumerate(lres): nres[i].append(v[1]) mres.append(sum([j for i,j in lres])/nbcurve) - print maxofmin + print(maxofmin) for y in nres: mpl.plot(x,y) mpl.plot(x,mres,linewidth=2) diff --git a/share/extension/mtgaxiom/mtgcompare.py b/share/extension/mtgaxiom/mtgcompare.py index 7ab97009..35498da2 100644 --- a/share/extension/mtgaxiom/mtgcompare.py +++ b/share/extension/mtgaxiom/mtgcompare.py @@ -31,6 +31,6 @@ def getpropforsubtree(mtg,root,initialmtg,initialroot,matched,rebuildclasses = ' nbmatched = len(matched) return 2*nbmatched/float(nbelements1+nbelements2) nbtotelem = nbelements1+nbelements2-nbmatched - print root,nbmatched,nbelements1,nbelements2,nbmatched/float(nbtotelem) + print (root,nbmatched,nbelements1,nbelements2,nbmatched/float(nbtotelem)) return nbmatched/float(nbtotelem) diff --git a/share/extension/mtgaxiom/mtgimport.py b/share/extension/mtgaxiom/mtgimport.py index 908dc0be..26d8e2d5 100644 --- a/share/extension/mtgaxiom/mtgimport.py +++ b/share/extension/mtgaxiom/mtgimport.py @@ -60,7 +60,7 @@ def nodelength(i): gul = [sum([nodelength(i) for i in ui]) for ui in gu] avg_length_gu = mean(gul) - print '**', avg_length_gu, min(gul), max(gul) + print('**', avg_length_gu, min(gul), max(gul)) leavesly = [g.parent(i[-1]) for i in gu] def last_year_ancestors(i): diff --git a/share/tutorial/lpy-paper12-examples/code2.py b/share/tutorial/lpy-paper12-examples/code2.py index 8bca021d..3611025f 100644 --- a/share/tutorial/lpy-paper12-examples/code2.py +++ b/share/tutorial/lpy-paper12-examples/code2.py @@ -3,7 +3,7 @@ def main(): lsys = Lsystem("lsystem1.lpy") - print lsys.dr # This would print 0.02 + print (lsys.dr) # This would print 0.02 lsys.axiom = Lstring("Apex(2)",lsys) lstring = lsys.axiom timer = Sequencer(0.1) diff --git a/share/tutorial/lpy-paper12-examples/code4.py b/share/tutorial/lpy-paper12-examples/code4.py index 81e6cc84..6acc52ca 100644 --- a/share/tutorial/lpy-paper12-examples/code4.py +++ b/share/tutorial/lpy-paper12-examples/code4.py @@ -12,7 +12,7 @@ def simulation(): lsystem = ComposedLsystem([a,a2b,b,b2a],[a2c,c]) lstring = lsystem.axiom - print lstring + print (lstring) lsystem.animate(nbsteps = 10) From 3b48347b8ae29acbee3d9c815172a1902dfaa754 Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Mon, 3 Feb 2020 17:47:24 +0100 Subject: [PATCH 07/11] improve appveyor config to have vc compiler --- appveyor.yml | 4 +++- conda/meta.yaml | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 26fab5b9..0200d5a5 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -1,5 +1,4 @@ platform: - - x86 - x64 environment: @@ -9,6 +8,9 @@ environment: CONDA_VERSION: 3 install: + - call "C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.cmd" /x64 + - call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x86_amd64 + - if errorlevel 1 exit 1 - git clone https://github.com/OpenAlea/appveyor-ci.git appveyor-ci - cd appveyor-ci - call install.bat diff --git a/conda/meta.yaml b/conda/meta.yaml index a4f1abb4..ff59dced 100644 --- a/conda/meta.yaml +++ b/conda/meta.yaml @@ -15,7 +15,7 @@ about: build: preserve_egg_dir: True - number: 5 + number: 6 requirements: build: - binutils_impl_linux-64<2.31.0 # [linux] From 669ed4bfa21d3d0013b554734e010b5b0d263ce1 Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Tue, 4 Feb 2020 09:39:20 +0100 Subject: [PATCH 08/11] fix problems with reading and saving file --- src/openalea/lpy/__version__.py | 2 +- src/openalea/lpy/gui/objectpanel.py | 2 +- src/openalea/lpy/gui/simulation.py | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/openalea/lpy/__version__.py b/src/openalea/lpy/__version__.py index 9a455e3c..c95651ce 100644 --- a/src/openalea/lpy/__version__.py +++ b/src/openalea/lpy/__version__.py @@ -1,4 +1,4 @@ -__version_number__ = 0x030000 +__version_number__ = 0x030001 __revision_str__="" diff --git a/src/openalea/lpy/gui/objectpanel.py b/src/openalea/lpy/gui/objectpanel.py index 62e2ac11..5d9350fc 100644 --- a/src/openalea/lpy/gui/objectpanel.py +++ b/src/openalea/lpy/gui/objectpanel.py @@ -711,7 +711,7 @@ def drawTextIn(self, text, x, y, width, below = False, color = None): tratio = mtw / float(tw) lt = len(text) nbchar = int(lt * tratio) -3 - text = text[0:nbchar/2]+'...'+text[lt-nbchar/2:] + text = text[0:int(nbchar/2)]+'...'+text[int(lt-nbchar/2):] tw = fm.width(text) px = (mtw-tw) / 2 py = width-1-fm.descent() diff --git a/src/openalea/lpy/gui/simulation.py b/src/openalea/lpy/gui/simulation.py index 40484f60..332f4449 100644 --- a/src/openalea/lpy/gui/simulation.py +++ b/src/openalea/lpy/gui/simulation.py @@ -279,8 +279,8 @@ def save(self): def saveas(self): bckupname = self.getBackupName() - qfname = QFileDialog.getSaveFileName(self.lpywidget,"Save L-Py file",self.fname if self.fname else '.',"Py Lsystems Files (*.lpy);;All Files (*.*)") - if qfname: + qfname, mfilter = QFileDialog.getSaveFileName(self.lpywidget,"Save L-Py file",self.fname if self.fname else '.',"Py Lsystems Files (*.lpy);;All Files (*.*)") + if qfname : fname = str(qfname[0]) if not os.path.exists(fname): self.readonly = False From 0d3dd1658cb45c8905c7e3cd0add7274ac5688ff Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Tue, 4 Feb 2020 09:45:34 +0100 Subject: [PATCH 09/11] use same file for log of lpy --- src/openalea/lpy/gui/lpyshell.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/openalea/lpy/gui/lpyshell.py b/src/openalea/lpy/gui/lpyshell.py index 31f14671..a845756f 100644 --- a/src/openalea/lpy/gui/lpyshell.py +++ b/src/openalea/lpy/gui/lpyshell.py @@ -14,8 +14,9 @@ def __init__(self, parent=None): exit the interpreter by Ctrl-D. """ if sys.executable.endswith('pythonw.exe'): - sys.stdout = open(tempfile.gettempdir() + '/lpystdout.txt', 'w') - sys.stderr = open(tempfile.gettempdir() + '/lpystderr.txt', 'w') + lpylog = open(tempfile.gettempdir() + '/lpylog.txt', 'w') + sys.stdout = lpylog + sys.stderr = lpylog RichJupyterWidget.__init__(self, parent) From 1d40bc7fb0236158352fce17f2092b218dd8322b Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Wed, 5 Feb 2020 19:39:11 +0100 Subject: [PATCH 10/11] fix problem with syntax error --- src/openalea/lpy/gui/lpystudio.py | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/src/openalea/lpy/gui/lpystudio.py b/src/openalea/lpy/gui/lpystudio.py index 66b91616..3ec030a9 100644 --- a/src/openalea/lpy/gui/lpystudio.py +++ b/src/openalea/lpy/gui/lpystudio.py @@ -475,11 +475,8 @@ def errorEvent(self,exc_info): fnames = ['',self.currentSimulation().getBaseName()] if st[0] in fnames : self.codeeditor.hightlightError(st[1]) - elif t == SyntaxError: - lst = v.message.split(':') - if len(lst) >= 3 and lst[0] in fnames: - self.codeeditor.hightlightError(int(lst[1])) - elif v.filename in fnames: + elif t == SyntaxError: + if v.filename in fnames: self.codeeditor.hightlightError(v.lineno) def endErrorEvent(self,answer): if self.debugger.running: From 19c3f03b41c05485bd8c7aa3ab6bc02fb7518599 Mon Sep 17 00:00:00 2001 From: Frederic Boudon Date: Wed, 5 Feb 2020 19:40:52 +0100 Subject: [PATCH 11/11] inc version --- src/openalea/lpy/__version__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/openalea/lpy/__version__.py b/src/openalea/lpy/__version__.py index c95651ce..0a01cdc3 100644 --- a/src/openalea/lpy/__version__.py +++ b/src/openalea/lpy/__version__.py @@ -1,4 +1,4 @@ -__version_number__ = 0x030001 +__version_number__ = 0x030002 __revision_str__=""