Re: [GRASS-dev] Min. req. of programming language standard support, GRASS GIS 8
On Thu, Jan 28, 2021 at 4:28 AM Nicklas Larsson via grass-dev < grass-dev@lists.osgeo.org> wrote: > > Let me put up a a suggestion for min. req. for coming GRASS GIS 8 as a > starting point of discussion: > - Python 3.7 > - C11 > - C++11 > Given that first release of Python 3.7 was in 2018-06-27, won't any system with Python 3.7 also have a compiler capable of handling C and C++ higher than C11/C++11? For example, if I'm reading Repology correctly, Debian Stable has Python 3.7 [1] and GCC 8 [2] which has at least some C17 support, C++17 support, and definitely C++14 support [3]. Similarly to the GDAL and PROJ issue where I don't think it is necessary to have GRASS C89/C++98 compliant when you need C++11 for GDAL anyway. Here, I think that either the C and C++ versions are unnecessary low or the Python version is too high if Debian Stable is a representative sample. [1] https://repology.org/project/python/packages [2] https://repology.org/project/gcc/packages [3] https://gcc.gnu.org/onlinedocs/gcc-8.2.0/gcc/Standards.html#C-Language ___ grass-dev mailing list grass-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/grass-dev
Re: [GRASS-dev] Min. req. of programming language standard support, GRASS GIS 8
On Wed, Feb 3, 2021 at 2:47 PM Anna Petrášová wrote: > > > On Tue, Feb 2, 2021 at 11:20 AM Nicklas Larsson > wrote: > >> >> Well, I don’t have a very strong opinion regarding 3.7, but personally >> I’d say 3.6 is an absolute minimum. I presume, for example, most of us >> would prefer to use f-strings for string formatting. >> > > yes, f-strings are nice although they have limitations for using with > translatable strings (Vashek can expand on that) > Right, it is important to note that the f-strings are great for formatting outputs and other strings in general, but don't work well with gettext. The two following lines are not equivalent. _("value: {a}").format(**locals()) _(f"value: {a}") There are still valid use cases for f-strings in GRASS, but it won't be messages. ___ grass-dev mailing list grass-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/grass-dev
Re: [GRASS-dev] Min. req. of programming language standard support, GRASS GIS 8
On Wed, Feb 3, 2021 at 6:30 AM Huidae Cho wrote: > > Thanks Nicklas for the great summary! That helped a lot. > > I was wondering if we have a list of all supported platforms somewhere? We have official downloads for Linux, Mac, and Windows. Are these three only "officially" supported platforms? I know GRASS is compilable on FreeBSD [1] and maybe (Open|Net)BSD. Is that it? Minix3 supports GDAL 1.11.3, PROJ 4.9.2, GEOS 3.5.0, and GCC 6.2.0 [2]. I know... they are a little behind. I think it is a bit more complicated, e.g. there is not one single Linux version. We need to make a decision not only about platforms, but also about platform versions. Traditionally, GRASS aims to be compatible with all currently supported platform versions. For RHEL, this would mean support for RHEL 7 (ignoring the extended support for RHEL 6 until 2024). For Debian, this would mean support for Stretch (Debian 9). For FreeBSD, this would mean support for FreeBSD 11.x. For Solaris, this would mean support for Solaris 11 (ignoring the extended support for Solaris 10 until 2024). I have previously tested GRASS on all these platforms, but not on all supported versions of these platforms. IMHO, it is ok if the current GRASS version is running on the current version of these OSs (RHEL, Debian, FreeBSD, Solaris) which are often used in production environments. The derived and often more up-to-date OSs like Fedora, Ubuntu, etc. do not seem to be a problem. Markus M > > Since we cannot (or will be difficult to) go back once we move to a newer C standard, I think we need to discuss what platforms we want to support officially or unofficially (?) first. Is [3] or [4] (GRASS 6.3) still valid? Has anyone tried all or some of those platforms recently (Sun Solaris (SPARC/Intel), Silicon Graphics Irix, HP-UX, DEC-Alpha, AIX, BSD, iPAQ/Linux and other UNIX compliant platforms)? I think at some point this list was removed from a release announcement. Maybe, we are being more realistic because many of these platforms are now irrelevant or we just don't have enough resources or interest to maintain such a list of supported platforms anymore? > > Best, > Huidae > > [1] https://www.freebsd.org/cgi/man.cgi?query=index§ion=3 > [2] http://www.minix3.org/pkgsrc/distfiles/local/3.4.0-2016Q3/ > [3] https://old.grass.osgeo.org/screenshots/platforms/ > [4] https://grass.osgeo.org/news/2008_04_23_announce_grass630/ > > > On Mon, Feb 1, 2021 at 4:25 PM Markus Metz wrote: >> >> A pity that Nicklas did not answer in this thread, see his answer in https://lists.osgeo.org/pipermail/grass-dev/2021-February/094913.html >> >> I have not studied the different C standards and the state of their implementation in different compilers and their different versions in depth, and thus appreciate very much the summary of Nicklas! >> >> IIUC, Nicklas recommends to allow C11 standard features in GRASS C code, with no need to change the current code base, and all compilers in all supported platforms apparently support C11. >> >> +1 from me, as long as all stock compilers on all supported platforms support C11 >> >> Markus M >> >> >> On Mon, Feb 1, 2021 at 8:56 AM Moritz Lennert < mlenn...@club.worldonline.be> wrote: >> > >> > >> > >> > Am 31. Januar 2021 22:15:53 MEZ schrieb Markus Metz < markus.metz.gisw...@gmail.com>: >> > >On Fri, Jan 29, 2021 at 11:19 PM Moritz Lennert < >> > >mlenn...@club.worldonline.be> wrote: >> > >> >> > >> >> > >> >> > >> Am 29. Januar 2021 20:54:06 GMT+00:00 schrieb Markus Metz < >> > >markus.metz.gisw...@gmail.com>: >> > >> >Hi Huidae, >> > >> > >> > >> >On Thu, Jan 28, 2021 at 6:30 PM Huidae Cho wrote: >> > >> >> >> > >> >> Markus, >> > >> >> >> > >> >> I think we have to think about what benefits it would bring to us by >> > >> >modernizing C code. Probably, not much at all. Personally, I would keep >> > >it >> > >> >as is because the minimum set of anything (e.g., ANSI C with no new >> > >> >features) would probably be more portable, I believe. In other words, >> > >what >> > >> >are we missing from C99? >> > >> > >> > >> >as I mentioned, there is no need to modernize the GRASS C code. The >> > >> >question is if we officially allow C99 features. >> > >> > >> > >> >For example a number of useful math-related functions and macros are only >> > >> >available with C99. See /usr/include/math.h on your system and search for >> > >> >C99. Also a number of features related to data types, particularly for >> > >> >various int datatypes (stdint.h), become available with C99. And the >> > >> >geographic lib in PROJ with src/geodesic.c wants C99. For new PROJ >> > >> >versions, C99 is a requirement. >> > >> >> > >> >> > >> If proj requires it, doesn't it automatically become a requirement for >> > >GRASS as well ? >> > > >> > >No, because the code base of other libs might have completely different >> > >compile requirements. A software can use functions and libs of other >> > >software packages, but does not need to follow the compile standards of >> >
Re: [GRASS-dev] Min. req. of programming language standard support, GRASS GIS 8
On Tue, Feb 2, 2021 at 11:20 AM Nicklas Larsson wrote: > > > > > > On Friday, 29 January 2021, 18:50:34 CET, Anna Petrášová < > kratocha...@gmail.com> wrote: > > > > > > > > On Thu, Jan 28, 2021 at 4:28 AM Nicklas Larsson via grass-dev < > grass-dev@lists.osgeo.org> wrote: > > Dear Devs! > > > > As a relatively new member of the GRASS GIS dev community, I have had to > search for information on mailing lists, old trac comments etc. regarding > coding practice and in particular minimum programming language standard > support. Ending up in not entirely conclusive understanding. Up until now, > I have been mostly involved in Python development and I’m still not > absolutely certain, although I assume 3.5 is minimum version. And I’m not > alone, see e.g. [1]. > > > > Now, I’ve encountered a similar dilemma with C standard support, > attempting to address compiler warnings [2], in particular with the PR > #1256 [3]. > > > > I would be great if there were a (one) place where the min support of > Python version, C (C89, C99, C11, C17…) and C++ (C++03, C++11, C++14 …) > standard is stated -- loud and clear. Obviously, there has to be a > consensus in the community on these matters for that to happen. Such a > statement will also have to be revised now and then. (A related question is > also whether or not to support 32 bit, which I know have been raised > recently). > > > > I’d appreciate your opinion is on this issue! > > Let me put up a a suggestion for min. req. for coming GRASS GIS 8 as a > starting point of discussion: > > - Python 3.7 > > - C11 > > - C++11 > > > > > > Best regards, > > Nicklas > > > > Regarding Python, not sure if we shouldn't set 3.6 as minimum for G8, it > is still used e.g. in Ubuntu 18. Any reason to set 3.7 as minimum, some > specific features we would want to use? > > Anna > > > > > > > [1] https://github.com/OSGeo/grass/issues/1241 > > [2] https://github.com/OSGeo/grass/issues/1247 > > [3] https://github.com/OSGeo/grass/pull/1256 > > > > ___ > > grass-dev mailing list > > grass-dev@lists.osgeo.org > > https://lists.osgeo.org/mailman/listinfo/grass-dev > > > > > > > > Well, I don’t have a very strong opinion regarding 3.7, but personally I’d > say 3.6 is an absolute minimum. I presume, for example, most of us would > prefer to use f-strings for string formatting. > yes, f-strings are nice although they have limitations for using with translatable strings (Vashek can expand on that) > > > On the other hand, 3.6 will reach end-of-support at the end of this year > right after its 5th birthday party and the support for data classes in 3.7 > may potentially offer intriguing applications in G8. > I noticed the data classes as well. Given 3.6 is reaching end-of-support soon, I agree with 3.7 for G8. I assume grass would be compatible with 3.6 for a while anyway. > Ubuntu 18 has Python 3.6 and Debian 9 has Python 3.5! What will make the > lowest common denominator? Debian 10 and Ubuntu 20 actually supports Python > 3.7 and 3.8 respectively. Forgive me if I’m ignorant, but isn’t it possible > to upgrade Python version on Ubuntu? Or is it just a pain with package > dependencies? Relying on default Python has never/rarely been a luxury for > other platforms. > > That being said, I think the most important part of this is that the > community make a clear decision on min. supported Python version. > > > Best, > Nicklas > ___ grass-dev mailing list grass-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/grass-dev
Re: [GRASS-dev] GSoC 2021 Project - Sunveer Singh
On Wed, 3 Feb 2021 at 14:15, Sunveer Singh wrote: > Dear Team, > > Dear Devs, > I am Sunveer Singh, I graduated from high school in 2021 and will start my > undergraduate studies in Fall 2021 and have been accepted into a university > so it makes me eligible to participate in GSoC this year. > > I was Google Code-in 2017 Grand Prize Winner, Google Code-in 2018 > Finalist, and Google Code-in 2019 Mentor with OSGeo. And I majorly worked > on GRASS GIS unit testing tasks during that time. And I would like to work > on a GSoC project with GRASS GIS related to it. > you can see his tests here https://github.com/OSGeo/grass/search?q=Sunveer&type=code > I found this following project and I would be happy to work on it this > year: > https://trac.osgeo.org/grass/wiki/GSoC/2017#Toolsforgeneratingunittestsfromexamplesinthemanual > > > I see that this project was skipped after 2017 and no one had worked on > it, so I would like to work on this as it is totally of my interest and my > skills. Will the mentors written on the page will be the same i.e Vaclav > Petras and Soeren Gebbert? > > Sunveer showed a lot of dedication and interest in GRASS GIS project, I think he would be a great candidate for GSOC Thank You > Sunveer > https://sunveersingh.github.io/ > > -- ciao Luca www.lucadelu.org ___ grass-dev mailing list grass-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/grass-dev
[GRASS-dev] GSoC 2021 Project - Sunveer Singh
Dear Team, I am Sunveer Singh, I graduated from high school in 2021 and will start my undergraduate studies in Fall 2021 and have been accepted into a university so it makes me eligible to participate in GSoC this year. I was Google Code-in 2017 Grand Prize Winner, Google Code-in 2018 Finalist, and Google Code-in 2019 Mentor with OSGeo. And I majorly worked on GRASS GIS unit testing tasks during that time. And I would like to work on a GSoC project with GRASS GIS related to it. I found this following project and I would be happy to work on it this year: https://trac.osgeo.org/grass/wiki/GSoC/2017#Toolsforgeneratingunittestsfromexamplesinthemanual I see that this project was skipped after 2017 and no one had worked on it, so I would like to work on this as it is totally of my interest and my skills. Will the mentors written on the page will be the same i.e Vaclav Petras and Soeren Gebbert? Thank You Sunveer https://sunveersingh.github.io/ ___ grass-dev mailing list grass-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/grass-dev