similar to: The finalizer of the externalPtr does not work when closing R?

Displaying 20 results from an estimated 5000 matches similar to: "The finalizer of the externalPtr does not work when closing R?"

2020 Apr 03
0
The finalizer of the externalPtr does not work when closing R?
See R_RegisterCFinalizerEx() and set onexit to nonzero. Here: https://github.com/wch/r-source/blob/9353ddfa8d30069ad8975e0364307d710f2488d5/src/include/Rinternals.h#L1279-L1280 Gabor On Fri, Apr 3, 2020 at 1:56 PM Wang Jiefei <szwjf08 at gmail.com> wrote: > > Hi all, > > I found that the finalizer of the externalPtr is not called when R is > quitting. However, manually
2020 Apr 03
0
[External] The finalizer of the externalPtr does not work when closing R?
Use R_RegisterFinalizerEx in your C code. See https://cran.r-project.org/doc/manuals/r-release/R-exts.html#External-pointers-and-weak-references This still gives you only "best effort"; for anything stronger you would need a different approach. In general, finalizers should only be used as a backstop, not as a primary resource management tool (in R or any other garbage-collected
2020 Mar 11
1
R CMD INSTALL cannot recognize full path on Windows
Jiefei, you did not commit all files into the example package - your example has things like RcppExports.cpp as well as additional flags which are not in your GH project. I suspect the issue is with the extra flags you're adding - those don't come from R. Please make sure you can replicate the issue with the GH package you created. Cheers, Simon * installing *source* package
2020 Mar 10
4
R CMD INSTALL cannot recognize full path on Windows
Oops, I think both of us forget to cite the r-devel channel. Best, Jiefei On Tue, Mar 10, 2020 at 5:13 AM Wang Jiefei <szwjf08 at gmail.com> wrote: > Thanks for your quick response, Tomas. > > Yes, this is a path issue, I think the problem is related to R, not the > Rtools make. I built an example package for reproducing the problem: > https://github.com/Jiefei-Wang/example
2016 Sep 15
1
Finalizer execution order question
Given an externalptr object 'pool' which protects an R object 'prot': # SEXP prot = (a dynamically updated list with handles) SEXP pool = R_MakeExternalPtr(p, R_NilValue, prot); R_RegisterCFinalizerEx(pool, fin_pool, TRUE); WRE explains that 'prot' remains in existence as long as 'pool' is around. Does this also mean 'prot' still exists when the
2008 Dec 07
1
Compile Packages on vista
Hi I''m trying to compile R packages on my vista (I''m very new on vista...). I installed Rtools, RExcel on a specific folder: c:\Rtools and gave full access. Unfortunately, I am still unable to compile any packages (may be still because of the security properties of vista). I checked several mailing list/forums/website but I did not found any solution. Does anybody have the
2004 May 03
1
Help making a simple R code only package
Hello, I am new to R and I am trying to figure out how to build and install a package with nothing but R code inside. I have run 'package.skeleton' to get the basic structure. When I run 'Rcmd INSTALL testPackage' I get this error message: make: *** No rule to make target `Files/R/rw1080'. Stop. *** Installation of testPackage failed *** When I run 'Rcmd build
2008 Jan 29
2
Problem with new("externalptr")
Hi, It seems that new("externalptr") is always returning the same instance, and not a new one as one would expect from a call to new(). Of course this is hard to observe: > new("externalptr") <pointer: (nil)> > new("externalptr") <pointer: (nil)> since not a lot of details are displayed. For example, it's easy to see that 2
2020 Mar 11
0
R CMD INSTALL cannot recognize full path on Windows
Thanks a lot for your suggestions. I see what you mean. I have removed all unnecessary files and dependences on https://github.com/Jiefei-Wang/example, but still no luck. I've tried to install the package as a user, not admin, but I got the same error. Also, I apologize for spamming the mail list. I will keep my reply as neat as possible. Martin has suggested checking the encoding of the file
2012 Oct 02
1
ffsave problems
Dear R friends. After having some troubles learning how to create a ffdf object, now I find myself having problems saving it. this is the data i´d like to save: str(DATA) List of 3 $ virtual: 'data.frame': 6 obs. of 7 variables: .. $ VirtualVmode : chr "double" "short" "integer" "integer" ... .. $ AsIs : logi FALSE FALSE FALSE
2020 Mar 11
0
R CMD INSTALL cannot recognize full path on Windows
Thanks, Jiefei, unfortunately your example does not work on my system, and also it is far from minimal. The error message you are getting is from Windows and could be caused for example by accidental quoting of the path using single quotes. Issues with RStudio or devtools would have to be discussed in their mailing lists/with their authors, but my guess is that the problem is in your local
2012 Dec 25
2
reinterpreting externalptr in R
Hi, I am using swig to build a wrapper for an c-function to use it in R. I would like to define a generic function, which gives back a void pointer. On the R side, I know what this pointer is pointing to, whether it is an integer or an string, or something else... but I need to somehow reinterpret the resulting "externalptr" into another form... a function that looks like the
2012 May 11
1
Passing externalptr to .C()
Greetings. 2.15.0 added this behavior http://developer.r-project.org/blosxom.cgi/R-devel/NEWS/2012/03/29#n2012-03-29 o Passing R objects other than atomic vectors, functions, lists and environments to .C() is now deprecated and will give a warning. Most cases (especially NULL) are actually coding errors. NULL will be disallowed in future. This seems to make sense,
2018 Mar 18
3
`@<-` modify its argument when slot is externalptr
Dear all, I am confused about the inconsistent behaviors of `@<-` operator when used in different ways. Consider the following example: library(inline) # Function to generate an externalptr object with random address new_extptr <- cfunction(c(), ' SEXP val = PROTECT(ScalarLogical(1)); SEXP out = PROTECT(R_MakeExternalPtr(&val, R_NilValue, val)); UNPROTECT(2);
2017 Apr 14
2
potential bug in attribute handling for externalptr
Is the following expected behavior? > mkext <- inline::cfunction(language="C", body='return R_MakeExternalPtr(NULL, install("tag"), R_NilValue);') > x <- mkext() > y <- x > attr(y, "foo") <- "bar" > attributes(x) $foo [1] "bar" I would expect that modifying y's attributes should not affect x. [Tested
2015 Nov 30
1
restarting samba using a cron job on Debian
The same happens to me on Debian 7 with the included Samba 4.1.17. Although relates to Ubuntu, this is the same issue: https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1357471 I can tell you that what triggers this are network connectivity issues between the DCs, even if they last a couple of seconds. Once the connectivity is restored, the replication stays broken unless Samba is restarted.
2015 Mar 25
2
[LLVMdev] [PATCH] Test failures
Hi all, I experienced some test failures under Linux, probably caused by r232936: In the test SanitizerCommon-Unit :: Sanitizer-i386-Test/MemoryMappingLayout.CodeRange the temporary test file was opened write-only, but was read from, what subsequently failed: Note: Google Test filter = MemoryMappingLayout.CodeRange [==========] Running 1 test from 1 test case. [----------] Global test
2018 Mar 21
2
[PATCH] tests: regressions: make test-big-heap use a temporary empty file
Newer versions of qemu use file locking for the images by default, and apparently that does not work with /dev/null. Since this test just calls qemu-img to get the format of an empty image, create a temporary one instead. --- tests/regressions/test-big-heap.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/tests/regressions/test-big-heap.c
2005 Jul 26
1
Error registering finalizer
What exactly is a reference object? I'm getting this error message attempting to register a finalizer: can only weakly reference/finalize reference objects I don't see any problem with the code... Here's what appears to be the relevant portions. setClass("PDNNObject", representation(handle = "externalptr", id =
2012 Dec 14
4
New Puppet User: Issues with pre-commit script
Hi Guys, I am new to puppet so please let me know if this is not the correct place for asking this question. I am setting up a new puppet environment running the latest 3.x version. I have the puppet master and client setup correctly and tested with deploying a simple file to the client. Now, I am working on adding all the configs to SVN since I will have all my users checkout the