vacuum icon indicating copy to clipboard operation
vacuum copied to clipboard

dashboard UI shows invalid paths with curly braces and truncation

Open viktorasm opened this issue 9 months ago • 2 comments

In dashboard UI, for some reason, there is some random replacements of ] to }, and weird truncation at the end of the line.

Image

I've tried a quick local hack and this seems to work:

-				rows = append(rows, strings.ReplaceAll(violation.Path, "]", "}"))
+				rows = append(rows, violation.Path+" ")
Image

..the space helps with the truncation issue, and not sure what was the purpose for the curly brace replacements.

viktorasm avatar Mar 16 '25 06:03 viktorasm

would you be able to do a pull request ,this will check if all unit test are passing , if so, it looks legitimate usually { } are more for path parameters in text here [] seems nicer / better

LasneF avatar Mar 17 '25 08:03 LasneF

The reason this exists, is because the TUI (terminal UI) library used by vacuum requires font colors to be defined by enclosing square brackets. This completely conflicts with the JSON path, so as a workaround I replaced with braces.

I don't think the issue has been resolved in the upstream library, so I am amazed this works. I will look into it a little deeper.

daveshanley avatar Mar 20 '25 21:03 daveshanley

Fixed in v0.18.0

https://quobix.com/vacuum/commands/dashboard/

dashboard has been completely rebuilt and this problem no longer exists.

daveshanley avatar Sep 16 '25 02:09 daveshanley