Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add GRASS r.mapcalculator, remove r.mapcalc #8444

Merged
merged 7 commits into from
Jan 7, 2019

Conversation

gioman
Copy link
Contributor

@gioman gioman commented Nov 8, 2018

Description

  1. GRASS "r.mapcalc" is a beast that because of its nature was always hard to try implement in QGIS/Processing, and in fact in NEVER worked
  2. "r.mapcalculator" is a GRASS python script that makes use of "r.mapcalc" and makes it possible to implement it in QGIS/Processing like almost any other GRASS tool
  3. We had lost "r.mapcalcultor" in QGIS 3 because this was not ported from GRASS64 to GRASS7, but now a very nice GRASS developer made the porting, so we will have again access to this very powerful tool

https://trac.osgeo.org/grass/ticket/3431#comment:7

  1. This should be merged once the ported script will make its own way into the main branch of GRASS7

Checklist

Reviewing is a process done by project maintainers, mostly on a volunteer basis. We try to keep the overhead as small as possible and appreciate if you help us to do so by completing the following items. Feel free to ask in a comment if you have troubles with any of them.

  • Commit messages are descriptive and explain the rationale for changes
  • Commits which fix bugs include fixes #11111 in the commit message next to the description
  • Commits which add new features are tagged with [FEATURE] in the commit message
  • Commits which change the UI or existing user workflows are tagged with [needs-docs] in the commit message and contain sufficient information in the commit message to be documented
  • I have read the QGIS Coding Standards and this PR complies with them
  • This PR passes all existing unit tests (test results will be reported by travis-ci after opening this PR)
  • New unit tests have been added for core changes
  • I have run the scripts/prepare-commit.sh script before each commit

@nyalldawson nyalldawson added this to the 3.6 milestone Nov 11, 2018
@nyalldawson
Copy link
Collaborator

GRASS "r.mapcalc" is a beast that because of its nature was always hard to try implement in QGIS/Processing, and in fact in NEVER worke

Is this a "NEVER EVER EVER" worked? Is there any chance a user could have a working model broken by dropping this?

@gioman
Copy link
Contributor Author

gioman commented Nov 12, 2018

Is this a "NEVER EVER EVER" worked? Is there any chance a user could have a working model broken by dropping this?

@nyalldawson I always followed closely any change in this module and personally I found it never worked (Windows or Linux).

@PedroVenancio
Copy link
Contributor

@nyalldawson

I confirm that despite the attempts done to make GRASS7 r.mapcalc work on Processing, it was never possible to completely overcome the issues described in the feature request / bug report: https://issues.qgis.org/issues/6894

Now with the port of r.mapcalcultor, it seems to be working very well!

@nyalldawson
Copy link
Collaborator

Ok, cool. Just scared about breaking stuff if it was working for some users previously. Could we get a unit test here too please?

@gioman
Copy link
Contributor Author

gioman commented Nov 13, 2018

Could we get a unit test here too please?

yes of course. Anyway this is not to merge yet as the script has not yet been merged in GRASS main tree.

@stale
Copy link

stale bot commented Nov 27, 2018

The QGIS project highly values your contribution and would love to see this work merged! Unfortunately this PR has not had any activity in the last 14 days and is being automatically marked as "stale". If you think this pull request should be merged, please check

  • that all unit tests are passing

  • that all comments by reviewers have been addressed

  • that there is enough information for reviewers, in particular

    • link to any issues which this pull request fixes

    • add a description of workflows which this pull request fixes

    • add screenshots if applicable

  • that you have written unit tests where possible
    In case you should have any uncertainty, please leave a comment and we will be happy to help you proceed with this pull request.
    If there is no further activity on this pull request, it will be closed in a week.

@stale stale bot added the stale Uh oh! Seems this work is abandoned, and the PR is about to close. label Nov 27, 2018
@PedroVenancio
Copy link
Contributor

This needs to wait for this change:

https://trac.osgeo.org/grass/ticket/3431#comment:9

@stale stale bot removed the stale Uh oh! Seems this work is abandoned, and the PR is about to close. label Nov 27, 2018
@gioman
Copy link
Contributor Author

gioman commented Dec 11, 2018

Note to myself. The tool will land in GRASS 7.6 and will called "r.mapcalc.simple", so this PR must be updated.

@stale
Copy link

stale bot commented Dec 25, 2018

The QGIS project highly values your contribution and would love to see this work merged! Unfortunately this PR has not had any activity in the last 14 days and is being automatically marked as "stale". If you think this pull request should be merged, please check

  • that all unit tests are passing

  • that all comments by reviewers have been addressed

  • that there is enough information for reviewers, in particular

    • link to any issues which this pull request fixes

    • add a description of workflows which this pull request fixes

    • add screenshots if applicable

  • that you have written unit tests where possible
    In case you should have any uncertainty, please leave a comment and we will be happy to help you proceed with this pull request.
    If there is no further activity on this pull request, it will be closed in a week.

@stale stale bot added the stale Uh oh! Seems this work is abandoned, and the PR is about to close. label Dec 25, 2018
@neteler
Copy link
Contributor

neteler commented Dec 27, 2018

Note, it has been backported to GRASS GIS 7.4 (to be part of upcoming 7.4.4) as well besides GRASS GIS 7.6 (upcoming 7.6.0):

@gioman
Copy link
Contributor Author

gioman commented Dec 28, 2018

@neteler very good news indeed, thanks!

@stale stale bot removed the stale Uh oh! Seems this work is abandoned, and the PR is about to close. label Dec 28, 2018
@PedroVenancio
Copy link
Contributor

@gioman @nyalldawson

Can we ensure that if GRASS 7.4.4 came out before 2019-01-18 (release date of QGIS 2.18.28), the Processing r.mapcalc.simple will be backported to be part of QGIS 2.18.28?

We should take advantage of this GRASS developers effort to include r.mapcalc.simple in the latest version of QGIS 2.18 LTR:

https://trac.osgeo.org/grass/ticket/3431#comment:27

The effort on the part of QGIS is minimal and the possibility of introducing bugs is nil.

On the other hand, it is also necessary to ensure that QGIS 2.18.28 is distributed with GRASS 7.4.4 on OSGeo4W and standalone for Windows.

What do you think?

@gioman
Copy link
Contributor Author

gioman commented Dec 28, 2018

We should take advantage of this GRASS developers effort to include r.mapcalc.simple in the latest version of QGIS 2.18 LTR:

agree

On the other hand, it is also necessary to ensure that QGIS 2.18.28 is distributed with GRASS 7.4.4 on OSGeo4W and standalone for Windows.

for this maybe also better include @jef-n in this discussion.

@neteler
Copy link
Contributor

neteler commented Dec 28, 2018

@gioman @nyalldawson

Can we ensure that if GRASS 7.4.4 came out before 2019-01-18 (release date of QGIS 2.18.28), the Processing r.mapcalc.simple will be backported to be part of QGIS 2.18.28?

We shall be able to make the GRASS GIS 7.4.4 release happen by then:
https://trac.osgeo.org/grass/milestone/7.4.4

Edit: Now proposed:
https://lists.osgeo.org/pipermail/grass-dev/2018-December/090810.html

@neteler
Copy link
Contributor

neteler commented Jan 4, 2019

@gioman @nyalldawson
Can we ensure that if GRASS 7.4.4 came out before 2019-01-18 (release date of QGIS 2.18.28), the Processing r.mapcalc.simple will be backported to be part of QGIS 2.18.28?

We shall be able to make the GRASS GIS 7.4.4 release happen by then:
https://trac.osgeo.org/grass/milestone/7.4.4

Done: Just now GRASS GIS 7.4.4 has been published:
https://trac.osgeo.org/grass/wiki/Release/7.4.4-News

along with
https://grass.osgeo.org/grass74/manuals/r.mapcalc.simple.html

@gioman
Copy link
Contributor Author

gioman commented Jan 7, 2019

https://trac.osgeo.org/grass/milestone/7.4.4

Done: Just now GRASS GIS 7.4.4 has been published:
https://trac.osgeo.org/grass/wiki/Release/7.4.4-News

along with
https://grass.osgeo.org/grass74/manuals/r.mapcalc.simple.html

@neteler thanks! I backported the processing patch to 2.18 and 3.4 branches.

@luipir
Copy link
Contributor

luipir commented Jan 7, 2019

@gioman can you find a way to check the installed grass version to avoid to have this command if grass is less that 7.4

@neteler
Copy link
Contributor

neteler commented Jan 7, 2019

@gioman can you find a way to check the installed grass version to avoid to have this command if grass is less that 7.4

grass --config version
7.4.4

@gioman
Copy link
Contributor Author

gioman commented Jan 7, 2019

@gioman can you find a way to check the installed grass version to avoid to have this command if grass is less that 7.4

I guess is possible, but I can't do it right now. I think is more important to have this merged anyway, as anyway we are shipping QGIS since long with a broken (it never worked) r.mapcalc module. Who will not have GRASS 7.4.4 will have a not working r.mapcalc.simple module, that do not change much in term of ux :)

@luipir
Copy link
Contributor

luipir commented Jan 7, 2019

@gioman will you add tests during A Coruña hackmeeting?

@gioman
Copy link
Contributor Author

gioman commented Jan 7, 2019

@gioman will you add tests during A Coruña hackmeeting?

yes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants