String Replacer (Dictionary): Allow to replace missing

Hi,

while harmonizing some data I noticed that the String Replacer (Dictionary) cannot cope with to be replaced but missing values. It would be helpful, i.e. to intentionally clear the data, that the node wouldn’t fail but maybe only throw a warning.

Adding to that, it appears that the error log is not quite accurate as it (tries to?) point towards the missing value

2024-12-05 13:43:10,929	ERROR String Replacer (Dictionary) 4:1815:0:678:0:739 Could not insert replacement string in row 'Row325'
 RowID  |   TLD    | Domain Count
--------+----------+--------------
 Row324 | engineer | 6315        
 Row325 | gov      | 6311        
 Row326 | film     | 6311        
          ^^^^
The replacement column contains a missing cell

Best
Mike

Hi @mwiegand ,

thanks for reporting. I was able to reproduce that the error message is incorrect and unclear. I opened a ticket for the developers (internal reference AP-23702).

Regarding the use of the String Replacer node for replacing missing values, I am not convinced. In typical use cases missing values are special and not just other values. Thus, I want to see from the workflow when they are treated. I understand that it might make building workflows easier, if the node supported this. However, I expect that it would make understanding workflows a lot harder, especially since missing values are a common points of confusion/failure.
We can use this thread to discuss and vote.

Have a nice day,
nan

2 Likes