Closed
Description
This is from @MerlinHeidemanns
Make a model called 'test4.stan' in your working directory.
Something like this is fine:
parameters {
real x;
}
model {
x ~ normal(0, 1);
}
Now create a directory 'test4'. cmdstan_model
will think the model is built and up to date and produce an error when running.
> dir.create('test4')
> mod = cmdstan_model('test4.stan')
Model executable is up to date!
> mod$sample()
Running MCMC with 4 sequential chains...
Error in rethrow_call(c_processx_exec, command, c(command, args), stdin, :
cannot start processx process './test4' (system error 13, Permission denied) @unix/processx.c:592 (processx_exec)
Type .Last.error.trace to see where the error occured
If you update the model, it builds and then gets put in that folder:
> mod = cmdstan_model('test4.stan')
Compiling Stan program...
> mod$sample()
Running MCMC with 4 sequential chains...
Error in rethrow_call(c_processx_exec, command, c(command, args), stdin, :
cannot start processx process './test4' (system error 13, Permission denied) @unix/processx.c:592 (processx_exec)
Type .Last.error.trace to see where the error occured
> list.files("test4/")
[1] "model-13792589c4fe"