How to exclude nodes without tag (learning how to create custom validation)

Hi all,

I’m exploring and would like to learn how to create custom validation rules.
Currently, I am practicing with creating a validation rule that checks for non matching crossing=* tags between node and way.

Here is my current code. It gets the job done so far. However, it is also flagging nodes that have no tags. How can I exclude nodes that have no tags in this code?

way[crossing =~ /^(unmarked|controlled|)$/] > node{ set .is_crossing_marked }
throwError: tr("Node does not match crosswalk crossing tag ");
group: tr(“non matching crossing tag”);

Any help is greatly appreciated, thanks!

2 posts - 2 participants

Read full topic

Ce sujet de discussion accompagne la publication sur