Skip to content

Commit c8ba87e

Browse files
vikingcran-robot
authored andcommitted
version 2.1.19
1 parent 17cfbe7 commit c8ba87e

15 files changed

+375
-207
lines changed

COPYING

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
R YAML package
22
==============
33

4-
Copyright (c) 2008-2017 Vanderbilt University
4+
Copyright (c) 2008-2016 Vanderbilt University
5+
Copyright (c) 2016-2018 Vanderbilt University Medical Center
56

67
Redistribution and use in source and binary forms, with or without
78
modification, are permitted provided that the following conditions are

DESCRIPTION

+10-7
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,19 @@
11
Package: yaml
22
Type: Package
33
Title: Methods to Convert R Data to YAML and Back
4-
Version: 2.1.18
5-
Date: 2018-03-08
4+
Version: 2.1.19
5+
Date: 2018-04-30
66
Suggests: testthat
7-
Author: Jeremy Stephens <[email protected]>
8-
Maintainer: Jeremy Stephens <[email protected]>
7+
Author: Jeremy Stephens [aut, cre], Kirill Simonov [aut], Yihui Xie [ctb],
8+
Zhuoer Dong [ctb], Hadley Wickham [ctb], Jeffrey Horner [ctb], reikoch [ctb],
9+
Will Beasley [ctb], Brendan O'Connor [ctb], Gregory R. Warnes [ctb]
10+
Maintainer: Jeremy Stephens <[email protected]>
911
License: BSD_3_clause + file LICENSE
10-
Description: Implements the 'libyaml' 'YAML' 1.1 parser and emitter (<http://pyyaml.org/wiki/LibYAML>) for R.
12+
Description: Implements the 'libyaml' 'YAML' 1.1 parser and emitter
13+
(<http://pyyaml.org/wiki/LibYAML>) for R.
1114
URL: https://github.com/viking/r-yaml/
1215
BugReports: https://github.com/viking/r-yaml/issues
1316
NeedsCompilation: yes
14-
Packaged: 2018-03-08 17:16:23 UTC; stephej1
17+
Packaged: 2018-04-30 20:56:56 UTC; stephej1
1518
Repository: CRAN
16-
Date/Publication: 2018-03-08 22:39:53 UTC
19+
Date/Publication: 2018-05-01 10:38:53 UTC

LICENSE

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
1-
YEAR: 2008-2017
2-
COPYRIGHT HOLDER: Jeremy Stephens
3-
ORGANIZATION: Vanderbilt University
1+
YEAR: 2008-2018
2+
COPYRIGHT HOLDER: Vanderbilt University Medical Center
3+
ORGANIZATION: Vanderbilt University Medical Center

MD5

+14-14
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,31 @@
1-
fa09576f1a178d6bbbed0a3a7c6658a9 *COPYING
2-
f1cc0da1fdfdd9c478ee6854736a3f97 *DESCRIPTION
3-
e58fbacdb9cfed939f4fd9b0d15f0bee *LICENSE
1+
bbba10d958545e3425cc20f316d9da75 *COPYING
2+
d440e0a33f696add5c278b305e61f52d *DESCRIPTION
3+
98b6f1d7e7a36de0353698db9027b614 *LICENSE
44
17a16244d43d0cfe5439535f4695dd7f *NAMESPACE
55
05097eadb441a850accca52b62df4211 *R/as.yaml.R
66
2e2a7e7cf24956e202fc4c73bad09b90 *R/read_yaml.R
77
41bba07a114c49bbdfe2b025403c89c0 *R/write_yaml.R
8-
b653b0cb420b4bc3f8e383c6dda1f26e *R/yaml.load.R
9-
1bc20160ad6346c041afb31e52ae4ad9 *R/yaml.load_file.R
8+
788be5758ce0fe969bd86b74f66bb11a *R/yaml.load.R
9+
363c5793776f7b432b777ecf3966d950 *R/yaml.load_file.R
1010
59d3ef441a03e63a67784ef7d111f8fe *R/zzz.R
11-
ace3f4e4c2bbe092a3c16a19e14f0597 *inst/CHANGELOG
12-
7fdf90be17ac849a6d21e83b76dfe6b8 *inst/THANKS
11+
635f5da6234f5b2358f1353156ff2b36 *inst/CHANGELOG
12+
f0a1646d0486e242e59e280cd842ae0d *inst/THANKS
1313
05861435cf308c70a8b7ba94fce61b8e *inst/implicit.re
1414
916e622be973c8ce2802a10976986ee9 *man/as.yaml.Rd
1515
a0d39a7ef9c9a3c2c5a3da0d2982e82b *man/read_yaml.Rd
1616
33e7e0b96f6aa83e85b13ede97212e9c *man/write_yaml.Rd
17-
e9c3e4d68ceaba9ce1c312c698c394be *man/yaml.load.Rd
17+
dbcccec0abd20440d047fbc8b94e873e *man/yaml.load.Rd
1818
6b0576349be43cf3d872205b41aff77d *src/Makevars
1919
55dfab3483ed1c7b2729f54ecb7d6079 *src/api.c
2020
fc3b40e7be71bf6c15fc119275f1c13d *src/dumper.c
2121
9c1a8f3fe9933a2c0bbb2152cfb6d3ee *src/emitter.c
2222
600ca8f17e1da02d661b336c6cd146bf *src/implicit.c
2323
c3ea5a68879f54f058c8bbfed18c55a0 *src/loader.c
2424
1a16662902d2e63e2af2470d0fe43794 *src/parser.c
25-
83a329ea074ab5d64e4b541545070bbb *src/r_emit.c
26-
a53c7b0c9cc17310ccb136459e81a37b *src/r_ext.c
27-
6bdfcb1b72ad3aeb3840781dbeed244f *src/r_ext.h
28-
639889e0f52d98aac2ed289ed41988f0 *src/r_parse.c
25+
b2fc52128050eea1e0a41e7a1805a8fb *src/r_emit.c
26+
7b6ed96ece58d8f8aecf4e725dbc587d *src/r_ext.c
27+
19e8716a3ff790a2f66859b58f19572e *src/r_ext.h
28+
3821f2c36959664e164242bbcc19c739 *src/r_parse.c
2929
095b4acfce41313fe01603812558230f *src/reader.c
3030
965007c37e953ccbcf0227b1d18552a3 *src/scanner.c
3131
ede6fecf08c77109b81f1054d4224a91 *src/writer.c
@@ -36,5 +36,5 @@ b70b0ade3126a031e5bf77d8aa9af4f2 *tests/testthat/files/test.yml
3636
12bc0646a0b62b994326688ccfcda5bd *tests/testthat/test_as_yaml.R
3737
fa1d250548643d2b2f69d3e15a396c94 *tests/testthat/test_read_yaml.R
3838
f38e5ea44a7a4e631bbd4ee15e8d5173 *tests/testthat/test_write_yaml.R
39-
5907343860e9f0ffd03620121fe16434 *tests/testthat/test_yaml_load.R
40-
0ef8c9da21dc10d06f9eae16894a1601 *tests/testthat/test_yaml_load_file.R
39+
4de5edd83c780d479f86e597cf3f4641 *tests/testthat/test_yaml_load.R
40+
5430539a598e9a8845b172bd0ded71d7 *tests/testthat/test_yaml_load_file.R

R/yaml.load.R

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
`yaml.load` <-
2-
function(string, as.named.list = TRUE, handlers = NULL, error.label = NULL) {
2+
function(string, as.named.list = TRUE, handlers = NULL, error.label = NULL, eval.expr = getOption("yaml.eval.expr", TRUE)) {
3+
eval.warning <- missing(eval.expr) && is.null(getOption("yaml.eval.expr"))
34
string <- enc2utf8(paste(string, collapse = "\n"))
4-
.Call(C_unserialize_from_yaml, string, as.named.list, handlers, error.label, PACKAGE="yaml")
5+
.Call(C_unserialize_from_yaml, string, as.named.list, handlers, error.label, eval.expr, eval.warning, PACKAGE="yaml")
56
}

R/yaml.load_file.R

+4-1
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,11 @@ function(input, error.label, ...) {
1111
else if (is.character(input) && nzchar(input[1])) {
1212
error.label <- input[1]
1313
}
14+
else {
15+
error.label <- NULL
16+
}
1417
}
15-
18+
1619
if (is.character(input)) {
1720
con <- file(input, encoding = 'UTF-8')
1821
on.exit(close(con), add = TRUE)

inst/CHANGELOG

+7-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
1+
v2.1.19
2+
- fix unserialization issues with int#base60 tag (reported by Nancy Irisarri)
3+
- add eval.expr option to yaml.load function
4+
- fix issue with error.label argument (patch by Gregory R. Warnes)
5+
- fix a few garbage collection protection issues
6+
17
v2.1.18
2-
- fix protection stack bugs (bug reported by Rich FitzJohn)
8+
- fix protection stack bugs (reported by Rich FitzJohn)
39

410
v2.1.17
511
- rewrite parsing functionality using pairlists instead of a self-managed

inst/THANKS

+1
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,4 @@ Patches submitted by:
88
- Hadley Wickham (867d1b0)
99
- Will Beasley (edefae9)
1010
- Zhuoer Dong (8febaba..28c89f4, 0e34af1)
11+
- Gregory R. Warnes (e3bf914)

man/yaml.load.Rd

+15-4
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,18 @@
77
Parse a YAML string and return R objects.
88
}
99
\usage{
10-
yaml.load(string, as.named.list = TRUE, handlers = NULL, error.label = NULL)
10+
yaml.load(string, as.named.list = TRUE, handlers = NULL, error.label = NULL,
11+
eval.expr = getOption("yaml.eval.expr", TRUE))
1112
yaml.load_file(input, error.label, ...)
1213
}
1314
%- maybe also 'usage' for other objects documented here.
1415
\arguments{
1516
\item{string}{ the YAML string to be parsed }
1617
\item{as.named.list}{ whether or not to return a named list for maps (TRUE by default) }
17-
\item{handlers}{ named list of custom handler functions for YAML types (see Details). }
18-
\item{input}{ a filename or connection. If \code{input} is a filename, that file must be encoded in UTF-8. }
19-
\item{error.label}{ a label to prepend to error messages (see Details). }
18+
\item{handlers}{ named list of custom handler functions for YAML types (see Details) }
19+
\item{input}{ a filename or connection; if \code{input} is a filename, that file must be encoded in UTF-8 }
20+
\item{error.label}{ a label to prepend to error messages (see Details) }
21+
\item{eval.expr}{ whether or not to evaluate expressions found in the YAML document (see Details) }
2022
\item{...}{ arguments to pass to yaml.load }
2123
}
2224
\details{
@@ -49,6 +51,15 @@
4951
connection object (via the \code{summary} function). You can explicity set
5052
\code{error.label} to \code{NULL} if you don't want to use this functionality.
5153

54+
There is a built-in handler that will evaluate expressions that are tagged
55+
with the \sQuote{!expr} tag. Currently this handler is enabled by default,
56+
but the handler is being disabled by default in an upcoming version for
57+
safety and security reasons. If you do not explicity set the
58+
\code{eval.expr} argument to \code{TRUE}, you will get a warning if an
59+
expression is evaluated. Alternately, you can set the option named
60+
\sQuote{yaml.eval.expr} via the \code{options} function to turn off the
61+
warning.
62+
5263
This function uses the YAML parser provided by libyaml, which conforms to the YAML 1.1
5364
specification.
5465
}

0 commit comments

Comments
 (0)