qualinsight-plugins-sonarqube-badges
qualinsight-plugins-sonarqube-badges copied to clipboard
Badge size/font
My badge size is slightly off. This appears to affect all badges.
http://bjj.is-a-player.com:9000/api/badges/measure?key=net.thejavashop%3Ajavampd%3Aorigin%2Fdevelop&metric=sqale_debt_ratio
Thanks
Hi, sorry for the late reply but I was on holidays until today.
This issue should not appear since 2.0.1: if the font is missing on the OS, a fallback font is supposed to be used and the badge size should be computed correctly. I need to better understand your context in order to help you. Can you thus provide the following information please ?
- operating system and version
- java version
- SonarQube version
- is it a docker based SQ instance ?
- SVG Badges plugin version
- Content of your
sonar.log
file (the best would be if you could stop your SQ instance, rename your existingsonar.log
file, then restart SQ, try to display a badge, then stop your SQ instance and send me the log file, this would ensure that we have fresh logs)
Note: it appears that your SQ instance is currently down, can you please restart it ? I need to check the content of the generated SVG file.
Cheers,
Michel
Thanks Michel. My SQ instance is back up. I'll get you the info asap.
Thanks
Hi Bill,
Could you manage retrieving the sonar.log file ? I checked the source of the generated SVG file and it looks like the plugin wasn't able to use the preferred font to compute image width. It tries then to use a fallback font (that is bundled with the plugin) but the width keeps being computed incorrectly (as if the sans-serif font was being used). Without the logs I won't be able to help you.
Best regards,
Michel
operating system and version CentOS Linux release 7.3.1611 (Core)
java version jdk1.8.0_25
SonarQube version 6.2
is it a docker based SQ instance ? No
SVG Badges plugin version 3.0.1
Content of your sonar.log file (the best would be if you could stop your SQ instance, rename your existing sonar.log file, then restart SQ, try to display a badge, then stop your SQ instance and send me the log file, this would ensure that we have fresh logs)
I didn't note much in the sonar.log but here it is. I launched a few different types of badges. Is there any other log that might help?
size calculation for metrics seems to be not correct. see attached screen shot:
the text for "quality gate" fits in the badge whereas "coverage on new code" is missing the first and the last character. Additionally the number display should be rounded with one decimal place. should i make an additional issue for that?
displayed in firefox 54.0 on Linux running sonarqube server 6.5 with badge plugin 3.0.1
Thx, Peter