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

"Save workspace image?" spam when running system(zip) functions #1283

Open
kaibagley opened this issue Mar 5, 2024 · 2 comments
Open

"Save workspace image?" spam when running system(zip) functions #1283

kaibagley opened this issue Mar 5, 2024 · 2 comments

Comments

@kaibagley
Copy link

kaibagley commented Mar 5, 2024

Hey,

Setup

OS: Windows 10
Emacs: 29.1 (build 2) 2023-08-02
ESS: 18.10.3snapshot

Issue

When running raster::KML, or utils::zip, the R buffer will suddenly print thousands of lines of:

Save workspace image? [y/n/c]: >

With no way to quit other than killing the R process in task manager.

What I've tried

I can see that raster::KML calls a function .zipKML, which then calls system(...), similar to utils::zip.

I've tried uninstalling 7zip, but same problem.
Even calling system("zip") with no other arguments causes the same issue.

This error only happens on Emacs/ESS, and not on Rstudio.

Thanks for any help!!!

@ppanko
Copy link

ppanko commented Sep 25, 2024

Having the same issue on Windows 11 with Emacs 27.1, ESS version 24.01.1 on a minimal config.

Calls involving system, Rcpp, rstan or brms all result in the R process printing "Save workspace image? [y/n/c/]" repeatedly and becoming unresponsive. This occurs both when sending lines to the process (e.g., ess-eval-region) and when evaluating a line directly in the inferior R buffer.

Attempts at debugging haven't resulted in anything; this behavior does not seem to be producing an error. The messages buffer offers no information either. Running the same code using Rstudio or RGui does not produce this issue.

@ppanko
Copy link

ppanko commented Jan 10, 2025

Toyed around with this issue some more today using both Emacs 27.1 and 29.1, ESS 20241216.1709, R 4.4.0 on Windows 11.

My minimal config:

(use-package ess
  :config
  (setq inferior-R-args "--vanilla --no-save")
  (setq ess-verbose t))

Code I am running:

library(Rcpp)

sourceCpp(
  code = "
  #include <Rcpp.h>
  using namespace Rcpp;
  // [[Rcpp::export]]
  int add_numbers(int a, int b) {
    return a + b;
  }"
)

With ess-eval-visibly at its default, running the lines above causes the process to terminate ("Process R finished at...") while 'nowait causes the process to hang indefinitely. The message and ESS buffers offer no clues.

R GUI and RStudio have no issues with the above code, as before.

Any help would be deeply appreciated.

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