Skip to content
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

Warning: Error in pngfun: invalid 'height' argument in logfiles #49

Open
sneumann opened this issue Nov 28, 2019 · 3 comments
Open

Warning: Error in pngfun: invalid 'height' argument in logfiles #49

sneumann opened this issue Nov 28, 2019 · 3 comments

Comments

@sneumann
Copy link
Member

Hi, we're getting in our logs:

Warning: Error in pngfun: invalid 'height' argument
  127: pngfun
  126: startPNG
  125: drawPlot
  111: <reactive:plotObj>
   95: drawReactive
   82: origRenderFunc
   81: output$plotScoresGroupsLegend
    1: runApp

Suggestion in rstudio/shiny#2136 (comment)
is to replace uiOutput("distPlot") with plotOutput("distPlot").
We have uiOutput() in two places:
https://github.com/ipb-halle/MetFamily/search?q=uiOutput&unscoped_q=uiOutput

@culpinnis
Copy link
Collaborator

In server_guiTabPca.R the default height is set to -1

scoresGroupsLegendHeight = -1

annotationLegendHeightPca = -1,

It should be calculated to the real value in server_guiPlots.R:
state_tabPca$annotationLegendHeightPca <<- annoLegendEntryHeight * (length(state_tabPca$annotationsPca$setOfAnnotations) + 1)

and for Hca

state_tabHca$annotationLegendHeightHca <<- annoLegendEntryHeight * (length(state_tabHca$annotationsHca$setOfAnnotations) + 1)

when drawDendrogramPlotImpl is called.
The error could be caused if the plot should be drawn without calling drawDendrogramPlotImpl or when the height value is overwritten by -1 again.
The function in
resetWorkspaceFunctions <- c(resetWorkspaceFunctions, function(){
could cause a reset of this value.
Further investigation is needed and will be done.

@culpinnis culpinnis self-assigned this Jan 17, 2020
@culpinnis culpinnis reopened this Aug 18, 2020
@culpinnis
Copy link
Collaborator

There are still plots with invalid height.

image

container (2).log

Maybe the same fix can be applied to output$plotHeatmap as in 6e0fc54#diff-0eff2e186b3075ea2ff8f167189909acR972-R974.

@culpinnis culpinnis removed their assignment Aug 18, 2020
@sneumann
Copy link
Member Author

sneumann commented Feb 19, 2024

Hi, we found that the "invalid height" happens if the user selects a 90% zoom scale in the Browser window, which makes the heatmap below the dendrogram causing the error message and to disappear. So current workaround is "don't zoom".
Yours, Steffen

P.S.: This sounds like same issue as https://stackoverflow.com/questions/59213316/shiny-renderplot-with-dynamic-height#comment104644786_59213670,
and maybe there is a solution in the first post in rstudio/shiny#2373 (comment),
and the original poster in https://stackoverflow.com/a/69668085 said he was not using the correct height function.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants