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

Issue with new version of spss.system.file #49

Closed
sciabolazza opened this issue Sep 17, 2020 · 9 comments
Closed

Issue with new version of spss.system.file #49

sciabolazza opened this issue Sep 17, 2020 · 9 comments

Comments

@sciabolazza
Copy link

I have been using memisc for a while to open some SPSS files.

I have just updated the package to the current version (0.99.25.5), and the function spss.system.file is not able anymore to open those files, and returns an error.

The error states that the variable "encoding" is not defined, when running the lines of code message(sprintf("File character set is '%S'.", encoding)).
The result is that the function spss.system.file fails to execute and it is not possible to load the file.

Please note that I went back using the old version of memisc (0.99.22) and with this package version I am able to correctly open the SPSS files with spss.system.file. This suggests that the problem is not with the file, but there might be a bug in the new version of spss.system.file.

P.s.
Your package has been extremely helpful over the years, thank you for your work.

@melff
Copy link
Owner

melff commented Sep 17, 2020

The current version on CRAN is 0.99.25.6 and the current version on GitHub is 0.99.26.3. Does the error occur with these versions as well? If yes, can you send me an example file? I am continuously using memisc with "real world" SPSS files and such an error has not occurred to me yet.

@sciabolazza
Copy link
Author

Sorry my bad, I mistyped the number of package version.
So the answer to your question is yes, the error occurs when I use the current version on CRAN (0.99.25.6).

I have a problem with sending you an example file.
The file producing the error contains sensible data so I cannot send that. Also, I cannot open the file with SPSS and extract a sub-sample to send it to you because I don't have SPSS. The only thing I could do is to open it with R using the old version package (0.99.22) and send a sub-sample of the file with a .rda extension, but I don't think it would be in any way useful.

However, if you think the .rda file would work, or there is anything else that I can do on my part to help you with the problem please let me know.

@melff
Copy link
Owner

melff commented Sep 17, 2020

Never mind. I'll try to figure it out without an example file.

@melff
Copy link
Owner

melff commented Sep 17, 2020

Could you please check whether build 0.99.26.4 (attached) solves the problem?
memisc_0.99.26.4.zip

@sciabolazza
Copy link
Author

sciabolazza commented Sep 18, 2020 via email

@melff
Copy link
Owner

melff commented Sep 18, 2020

This is hopefully fixed with the latest commit. Could you please check with the attached build?
memisc_0.99.26.4.zip

@sciabolazza
Copy link
Author

sciabolazza commented Sep 18, 2020 via email

@melff
Copy link
Owner

melff commented Sep 18, 2020

Thanks for the report. Apparently 'WINDOWS-1256' is not included in the character vector returned by iconvlist() on your machine (it is on mine though). But it still may be a (difficult to spot) bug. What do you see if you enter "WINDOWS-1256" %in% iconvlist() into the R command line?

@sciabolazza
Copy link
Author

sciabolazza commented Sep 18, 2020 via email

@melff melff closed this as completed Sep 23, 2020
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