grass icon indicating copy to clipboard operation
grass copied to clipboard

[Bug] g.gui.gmodeler: having `%` in module's arguments makes the model invalid

Open pesekon2 opened this issue 1 year ago • 0 comments

Describe the bug

If % is included in any of the model's modules' parameters, the validator complains that the model is invalid. This is caused by the fact that it thinks that it is a variable that is undefined. The model can run but this message is annoying (and wrong).

To reproduce

Try to put % into some parameter. The good option where this can happen often is v.db.select/v.extract with the where option (col1 LIKE 'A%').

Idea for solution

Change the syntax for variables in the modeler. The pure % prefix is bad because it can fail in case of variables like %d and %donkey (one of them is pseudorandomly chosen; if it chooses d over donkey, it thinks that onkey is a string following the variable).

System description

  • Operating System: Linux (Ubuntu)
  • GRASS GIS version: main as of 60f67276fbee985042f9fc571f824bb2c863ffbe

pesekon2 avatar Jun 17 '24 13:06 pesekon2