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

Console locks up when viewing previous plot #5020

Open
grasshoppermouse opened this issue Oct 15, 2024 · 3 comments
Open

Console locks up when viewing previous plot #5020

grasshoppermouse opened this issue Oct 15, 2024 · 3 comments
Labels
area: plots Issues related to Plots category. lang: r support

Comments

@grasshoppermouse
Copy link

System details:

Positron and OS details:

Positron Version: 2024.10.0 (Universal) build 14
Code - OSS Version: 1.93.0
Commit: 901ab5d
Date: 2024-10-09T15:26:55.363Z
Electron: 30.4.0
Chromium: 124.0.6367.243
Node.js: 20.15.1
V8: 12.4.254.20-electron.0
OS: Darwin arm64 23.6.0

Interpreter details:

R 4.4.0

Describe the issue:

Clicking on a previous plot locks up the console.

Steps to reproduce the issue:

library(qgraph)
data(big5)
data(big5groups)

# First plot
qgraph(cor(big5),minimum=0.25,groups=big5groups, legend=TRUE,borders=FALSE, title = "Big 5 correlations")

# Second identical plot
qgraph(cor(big5),minimum=0.25,groups=big5groups, legend=TRUE,borders=FALSE, title = "Big 5 correlations")

After clicking on the first plot (perhaps resizing it) the console locks up for a long time (e.g., unable to run R functions like ls())

Expected or desired behavior:

Able to view previous plots without the console locking up

Were there any error messages in the UI, Output panel, or Developer Tools console?

Error popup:

Error rendering plot to 'Auto' size: RPC timed out after 30 seconds: {"jsonrpc":"2.0","method":"render","params":{"size":{"height":695,"width":919},"pixel_ratio":2,"format":"png"}} (-32603)

Another error:

Error rendering plot to 'Auto' size: RPC timed out after 30 seconds: {"jsonrpc":"2.0","method":"get_intrinsic_size"} (-32603)

@jmcphers
Copy link
Collaborator

I can reproduce this:

Image

@jmcphers
Copy link
Collaborator

This doesn't reproduce outside qgraph as far as I can tell, likely an interaction between how that package draws graphics and how we manage the graphics device. I didn't see any errors in the R kernel logs, but did notice hundreds of these messages where we switch back and forth between gd_mode 1/0:

[R]   2024-10-15T16:11:06.713576Z  INFO  [graphics] gd_mode: 1
[R]     at crates/ark/src/plots/graphics_device.rs:499
[R] 
[R]   2024-10-15T16:11:06.713605Z  INFO  [graphics] gd_mode: 0
[R]     at crates/ark/src/plots/graphics_device.rs:499
[R] 
[R]   2024-10-15T16:11:06.713792Z  INFO  [graphics] gd_mode: 1
[R]     at crates/ark/src/plots/graphics_device.rs:499
[R] 
...

@juliasilge juliasilge added the area: plots Issues related to Plots category. label Oct 15, 2024
@jmcphers jmcphers added this to the Release Candidate milestone Oct 15, 2024
@loafing-cat

This comment has been minimized.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: plots Issues related to Plots category. lang: r support
Projects
None yet
Development

No branches or pull requests

4 participants