Skip to content

Commit

Permalink
increase timeouts for render PDFs
Browse files Browse the repository at this point in the history
Signed-off-by: Jan-Otto Kröpke <[email protected]>
  • Loading branch information
jkroepke committed Aug 22, 2024
1 parent 6020e45 commit 713e95c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/plugin/dashboard/browser.go
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ func (d *Dashboard) fetchBrowser(ctx context.Context, expandRows bool) (BrowserD
//nolint:cyclop
func (d *Dashboard) fetchPanelDataFromBrowser(_ context.Context, dashURL string, expandRows bool) (BrowserData, error) {
tab := d.chromeInstance.NewTab(d.logger, d.conf)
tab.WithTimeout(1 * time.Minute)
tab.WithTimeout(5 * time.Minute)

defer tab.Close(d.logger)

Expand All @@ -126,7 +126,7 @@ func (d *Dashboard) fetchPanelDataFromBrowser(_ context.Context, dashURL string,
return BrowserData{}, fmt.Errorf("error waiting for #page-scrollbar: %w", err)
}

if err := tab.RunWithTimeout(5*time.Second, chromedp.Evaluate(javascriptScrollToBottom, nil, chrome.WithAwaitPromise)); err != nil {
if err := tab.RunWithTimeout(30*time.Second, chromedp.Evaluate(javascriptScrollToBottom, nil, chrome.WithAwaitPromise)); err != nil {
return BrowserData{}, fmt.Errorf("error scrolling to bottom: %w", err)
}

Expand Down

0 comments on commit 713e95c

Please sign in to comment.