taurus-org / taurus

Moved to https://gitlab.com/taurus-org/taurus
http://taurus-scada.org
43 stars 46 forks source link

Avoid warning on strings with replacement fields #1151

Closed cpascual closed 3 years ago

cpascual commented 3 years ago

TaurusLabel.displayValue fails when displaying a string attribute whose value contains a replacement field, and falls back to the default representation with a warning. Avoid this by using a custom string formatter that ignores missing keys when formatting a string. Thanks to @vallsv for the proposed solution.

Fixes #1149

vallsv commented 3 years ago

I can confirm it works.