[Rd] make check-all fails on F8

Marc Schwartz marc_schwartz at comcast.net
Fri Nov 9 18:41:02 CET 2007


Hi all,

Clean install of F8 yesterday. This was not an upgrade, as I did some
re-partitioning of my HD to remove Windows (finally...) and no-longer
have a dual-boot laptop.

Using R 2.6.0 patched from SVN (rev 43319), which was the last rev that
I had on F7 and which passed all tests, I am now getting errors when
running make check-all on F8.

I have isolated the problem to the regression tests.

I have attached the two relevant files here. When running make
check-all, I get:

...
running regression tests
make[3]: Entering directory `/home/marcs/R.Files/SourceCode/SVN/tests'
running code in 'reg-tests-1.R' ... OK
running code in 'reg-tests-2.R' ... OK
comparing 'reg-tests-2.Rout' to './reg-tests-2.Rout.save' ... OK
running code in 'reg-IO.R' ... OK
comparing 'reg-IO.Rout' to './reg-IO.Rout.save' ...44c44
< In readLines("testIO.R") : incomplete final line found on 'testIO.R'
---
> In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
88c88
< In readLines("testIO.R") : incomplete final line found on 'testIO.R'
---
> In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
111c111
< In readLines("testIO.R") : incomplete final line found on 'testIO.R'
---
> In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
134c134
< In readLines("testIO.R") : incomplete final line found on 'testIO.R'
---
> In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
make[3]: *** [reg-IO.Rout] Error 1
make[3]: Leaving directory `/home/marcs/R.Files/SourceCode/SVN/tests'
make[2]: *** [test-Reg] Error 2
make[2]: Leaving directory `/home/marcs/R.Files/SourceCode/SVN/tests'
make[1]: *** [test-all-basics] Error 1
make[1]: Leaving directory `/home/marcs/R.Files/SourceCode/SVN/tests'
make: *** [check-all] Error 2



If I just run a diff on these two files, I get:

$ diff reg-IO.Rout.save reg-IO.Rout.fail
2c2
< R version 2.6.0 Under development (unstable) (2007-05-22 r41673)
---
> R version 2.6.0 Patched (2007-11-01 r43319)
59c59
< In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
---
> In readLines("testIO.R") : incomplete final line found on 'testIO.R'
103c103
< In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
---
> In readLines("testIO.R") : incomplete final line found on 'testIO.R'
126c126
< In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
---
> In readLines("testIO.R") : incomplete final line found on 'testIO.R'
149c149
< In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
---
> In readLines("testIO.R") : incomplete final line found on 'testIO.R'



I thought that I was going blind, as I did not see any differences.
However, it is blindingly subtle. On the 'save' version of the file,
there is a space character ' ' at the end of the line, whereas on the
'fail' version of the line, it ends at the single quote character.

I verified this using hex mode in Emacs. In the 'save' version of the
file, the line, after the single quote, ends with '200a', whereas in the
'fail' version of the file, the line ends with '0a'.

I went back to my last F7 backup to check the same files from my last
build.

In the 'save' version of the file, the same lines also end with '200a'.
In the 'pass' version of the file, the line ends with '0a', which is the
same as the 'fail' version of the file on F8.

So on F7, despite the differences in line ends, make check-all passed.

I have been looking ("tunnel vision") at this now for several hours
going back to last night, and am probably missing something basic here,
but is this the result of a change in the behavior of diff on F8, or is
something else going on that I am just missing?

Thanks,

Marc Schwartz

-------------- next part --------------

R version 2.6.0 Patched (2007-11-01 r43319)
Copyright (C) 2007 The R Foundation for Statistical Computing
ISBN 3-900051-07-0

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> ## NB: this file must be a DOS (CRLF) format file
> 
> ## Keep comments and original formatting
> options(keep.source=TRUE)
> 
> ## simple tests that multiple lines are read correctly
> print(2+3)
[1] 5
> print(4+5)
[1] 9
> 
> ## generate some files to source
> 
> z <- c("#line 1", "2+3", "ls()", "pi", "# last line")
> 
> ## ========  LF file
> cat(z, file="testIO.R", sep="\n")
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"

> pi
[1] 3.141593
> unlink("testIO.R")
> 
> ## ======== LF file, incomplete final line
> zz <- file("testIO.R", "wt")
> cat(z, file=zz, sep="\n")
> cat("5+6", file=zz)
> close(zz)
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
[6] "5+6"        
Warning message:
In readLines("testIO.R") : incomplete final line found on 'testIO.R'
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593

> # last line
> 5+6
[1] 11
> unlink("testIO.R")
> 
> ## ======== CRLF file
> cat(z, file="testIO.R", sep="\r\n")
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
> unlink("testIO.R")
> 
> ## ======== CRLF file, incomplete final line
> zz <- file("testIO.R", "wt")
> cat(z, file=zz, sep="\r\n")
> cat("5+6", file=zz)
> close(zz)
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
[6] "5+6"        
Warning message:
In readLines("testIO.R") : incomplete final line found on 'testIO.R'
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593

> # last line
> 5+6
[1] 11
> unlink("testIO.R")
> 
> ## ======== CR file
> cat(z, file="testIO.R", sep="\r")
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
Warning message:
In readLines("testIO.R") : incomplete final line found on 'testIO.R'
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593
> unlink("testIO.R")
> 
> ## ======== CR file, incomplete final line
> zz <- file("testIO.R", "wt")
> cat(z, file=zz, sep="\r")
> cat("\r5+6", file=zz)
> close(zz)
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
[6] "5+6"        
Warning message:
In readLines("testIO.R") : incomplete final line found on 'testIO.R'
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593

> # last line
> 5+6
[1] 11
> unlink("testIO.R")
> 
> ## end of reg-IO.R: the next line has no EOL chars
> 2 + 2
[1] 4
> 
-------------- next part --------------

R version 2.6.0 Under development (unstable) (2007-05-22 r41673)
Copyright (C) 2007 The R Foundation for Statistical Computing
ISBN 3-900051-07-0

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> ## NB: this file must be a DOS (CRLF) format file
> 
> ## Keep comments and original formatting
> options(keep.source=TRUE)
> 
> ## simple tests that multiple lines are read correctly
> print(2+3)
[1] 5
> print(4+5)
[1] 9
> 
> ## generate some files to source
> 
> z <- c("#line 1", "2+3", "ls()", "pi", "# last line")
> 
> ## ========  LF file
> cat(z, file="testIO.R", sep="\n")
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"

> pi
[1] 3.141593
> unlink("testIO.R")
> 
> ## ======== LF file, incomplete final line
> zz <- file("testIO.R", "wt")
> cat(z, file=zz, sep="\n")
> cat("5+6", file=zz)
> close(zz)
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
[6] "5+6"        
Warning message:
In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593

> # last line
> 5+6
[1] 11
> unlink("testIO.R")
> 
> ## ======== CRLF file
> cat(z, file="testIO.R", sep="\r\n")
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
> unlink("testIO.R")
> 
> ## ======== CRLF file, incomplete final line
> zz <- file("testIO.R", "wt")
> cat(z, file=zz, sep="\r\n")
> cat("5+6", file=zz)
> close(zz)
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
[6] "5+6"        
Warning message:
In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593

> # last line
> 5+6
[1] 11
> unlink("testIO.R")
> 
> ## ======== CR file
> cat(z, file="testIO.R", sep="\r")
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
Warning message:
In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593
> unlink("testIO.R")
> 
> ## ======== CR file, incomplete final line
> zz <- file("testIO.R", "wt")
> cat(z, file=zz, sep="\r")
> cat("\r5+6", file=zz)
> close(zz)
> readLines("testIO.R")
[1] "#line 1"     "2+3"         "ls()"        "pi"          "# last line"
[6] "5+6"        
Warning message:
In readLines("testIO.R") : incomplete final line found on 'testIO.R' 
> source("testIO.R", echo=TRUE)

> #line 1
> 2+3
[1] 5

> ls()
[1] "z"  "zz"

> pi
[1] 3.141593

> # last line
> 5+6
[1] 11
> unlink("testIO.R")
> 
> ## end of reg-IO.R: the next line has no EOL chars
> 2 + 2
[1] 4
> 


More information about the R-devel mailing list