-
Notifications
You must be signed in to change notification settings - Fork 314
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Captions cut if panel height limited #119
Comments
Hi, Thanks, I'm glad to hear you are finding the reporter valuable. The reporter calls grafana to render the panel PNGs. This uses an API that is also exposed on the Grafana UI; so can test whether you get the same results there? To do this you need to go to the panel menu -> Share -> Direct link rendered image. |
It is the same results with Direct Link as in grafana UI. |
Interesting. I suspect this has to do with the size format parameters the reporter passes along to this call to set the size of the image.
If you look at the reporter logs, you should see something like ```2019/03/15 07:54:55 Reporter called2019/03/15 07:54:55 Called with api Token: eyJrIjoiTTZhdVVLeHoySUo0SHlmZm41U21saUFVVXRHVlB6eWMiLCJuIjoicmVwb3J0ZXIiLCJpZCI6MX0=2019/03/15 07:54:55 Called without variable2019/03/15 07:54:55 Called with dashboard: Y4N5w6pmk2019/03/15 07:54:55 Called with time range: {1548975600000 1550228399000}2019/03/15 07:54:55 Connecting to dashboard at http://localhost:3000/api/dashboards/uid/Y4N5w6pmk2019/03/15 07:54:55 Populated dashboard datastructure: {Title:Temp - test text panel! Description: VariableValues: Rows:[] Panels:[{Id:1 Type:text Title:Panel Title} {Id:2 Type:text Title:Panel with many rows} {Id:3 Type:table Title:Table with single row} {Id:4 Type:text Title:Panel with one row} {Id:6 Type:singlestat Title:Singlestat panel} {Id:5 Type:graph Title:Panel Title} {Id:7 Type:table Title:Table with many rows and no scrolling} {Id:8 Type:table Title:Scrolling table with many rows}]}2019/03/15 07:54:55 Downloading image 1 http://localhost:3000/render/d-solo/Y4N5w6pmk/_?from=1548975600000&height=100&panelId=1&theme=light&to=1550228399000&width=10002019/03/15 07:54:55 Downloading image 3 http://localhost:3000/render/d-solo/Y4N5w6pmk/_?from=1548975600000&height=500&panelId=3&theme=light&to=1550228399000&width=10002019/03/15 07:54:55 Downloading image 2 http://localhost:3000/render/d-solo/Y4N5w6pmk/_?from=1548975600000&height=100&panelId=2&theme=light&to=1550228399000&width=10002019/03/15 07:54:55 Downloading image 6 http://localhost:3000/render/d-solo/Y4N5w6pmk/_?from=1548975600000&height=150&panelId=6&theme=light&to=1550228399000&width=3002019/03/15 07:54:55 Downloading image 4 http://localhost:3000/render/d-solo/Y4N5w6pmk/_?from=1548975600000&height=100&panelId=4&theme=light&to=1550228399000&width=10002019/03/15 07:54:59 Downloading image 5 http://localhost:3000/render/d-solo/Y4N5w6pmk/_?from=1548975600000&height=500&panelId=5&theme=light&to=1550228399000&width=10002019/03/15 07:55:00 Downloading image 7 http://localhost:3000/render/d-solo/Y4N5w6pmk/_?from=1548975600000&height=500&panelId=7&theme=light&to=1550228399000&width=10002019/03/15 07:55:00 Downloading image 8 http://localhost:3000/render/d-solo/Y4N5w6pmk/_?from=1548975600000&height=500&panelId=8&theme=light&to=1550228399000&width=10002019/03/15 07:55:09 Calling LaTeX - preprocessing2019/03/15 07:55:10 Calling LaTeX and building PDF2019/03/15 07:55:10 Extracted filename from dashboard title: Temp - test text panel!.pdf2019/03/15 07:55:10 Report generated correctly```Notice the `height` and `width` parameters passed along to the render API. What parameters where present (if any) when you invoked this from the Grafana UI? Can you reproduce the behaviour form the Grafana UI by adding these parameters? On Tuesday, March 19, 2019, 3:21:16 PM GMT+2, sfl3005 <notifications@github.com> wrote:
It is the same results with Direct Link as in grafana UI.
All 10 captions are present.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub, or mute the thread.
|
this graph is Id 7. In Grafana logs: If I use this URL (with height=1000), graph is diplayed correctly as you can see below |
Do you know why the height had to manually be increased to obtain all the caption ? How this can be integrated in the template ? |
This will require some investigation. At the moment the reporter hard codes the size of the png it requests, but corner cases like these makes it clear the approach should be improved somehow. Any feedback or ideas are welcome. |
Loosely related to #72 |
Solved by enabling new grid-layout flag (-grid-layout=1). See #162 (comment) for an example. |
Hi,
grafana-reporter is a wonderfull tool and I use it day to day !
I encountered an issue when generating pdf report on a graph with more than 6 items. On the graph all items are present but only 6 items are displayed on the graph caption.
how can I increase caption item count in pdf report ?
Thanks in advance
The text was updated successfully, but these errors were encountered: