Skip to content

add customizable responses's time for prompts #291

Open

Description

@capitantyler

It would be possible add customizable response's time for possible Rstudio form's prompts?
I am looking at the code and this time was set in 10 secs, which is too short to fill them.

I have been having problems running jobs from RStudio if it has Rstudio prompts inside.

Activity

  1. kevinushey commented on Jan 8, 2024

    @kevinushey
    Contributor

    Can you please give an example? AFAIK RStudio shouldn't be timing out in any of the prompts exposed to rstudioapi.

  2. capitantyler commented on Jan 9, 2024

    @capitantyler
    Author

    The mentioned code is in the remote.R line 65

    # check for response
      if (file.exists(responseFile))
        break
    
      # check for lack of response
      diff <- difftime(Sys.time(), now, units = "secs")
      if (diff > 10)
        stop("RStudio did not respond to rstudioapi IPC request")
    
      # wait a bit
      Sys.sleep(0.1)
    
    }
    
  3. kevinushey commented on Jan 9, 2024

    @kevinushey
    Contributor

    Ahh, thanks -- so this is specifically for the case where rstudioapi is being invoked remotely; that is, from within an R child process. We can take a look at that.

  4. capitantyler commented on Jan 10, 2024

    @capitantyler
    Author

    Well, I called it from a R Job, Besides, I filled the prompt manually.

  5. added 3 commits that reference this issue on Jul 4, 2024
    c1c45f2
    1c9c06e
    f2cc66e
  6. jonovik commented on Jul 4, 2024

    @jonovik

    I created a pull request to solve this, but am a bit surprised it was not autolinked here:

    #301

    Sorry about the force pushes to my fork; I didn't realize they were being linked here before I finalized my pull request. Please focus on the latest one (f2cc66e), and I'll make no more force pushes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions