-
Notifications
You must be signed in to change notification settings - Fork 38
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
profvis doesn't draw anything #15
Comments
Hm, it looks like it happens when a function is defined and called within another function, and that outer function is defined outside of a f1 <- function() {
g <- function() {
pause(0.1)
}
g()
}
profvis({
f1()
}) But these work: # No inner function
f2 <- function() {
pause(0.1)
}
profvis({
f2()
})
# Inner function is returned, then called from inside profvis()
f3 <- function() {
g <- function() {
pause(0.1)
}
g
}
profvis({
x <- f3()
x()
})
# Outer function is defined within profvis()
profvis({
f4 <- function() {
g <- function() {
pause(0.1)
}
g()
}
f4()
}) |
👍 I'm also having this problem. |
I have a feeling that it won't be possible to fix this -- the R profiler output simply doesn't contain enough information to retrieve the source code that's outside of the |
This is fixed now - it simply won't try to display code that's outside of the Simplified test app for future reference: library(profvis)
f <- function() {
# This empty line is needed
pause(0.1)
}
profvis({ f() }) |
@xshi0001 Can you file a new issue? And please include the output of |
Hi, I know this is closed, but I experienced the same thing. Since this is the only place that pops up on Google, I'd like to add, that profvis gives a blank screen when your path contains spaces. |
@hwpvdtoorn Thanks for the report. Can you file a new issue for this? And in that issue, can you tell us which path has spaces -- for example, is it the temporary directory? |
Hi, thanks for your reply. I tried to create an example but unfortunately that worked normally, so I can't repeat this. |
I am trying to profile complex optimization problem with
profvis
but when trying to print the output the browser renders the output as blank screen. Same thing with Rstudio's editor.I managed to reproduce the problem with this simple code:
The text was updated successfully, but these errors were encountered: