Skip to content

Commit 6f39af2

Browse files
authored
Merge pull request #300 from mrc-ide/mrc-4446
2 parents d5e2958 + 5c98040 commit 6f39af2

File tree

5 files changed

+7
-3
lines changed

5 files changed

+7
-3
lines changed

DESCRIPTION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: odin
22
Title: ODE Generation and Integration
3-
Version: 1.5.5
3+
Version: 1.5.6
44
Authors@R: c(person("Rich", "FitzJohn", role = c("aut", "cre"),
55
email = "rich.fitzjohn@gmail.com"),
66
person("Thibaut", "Jombart", role = "ctb"),

R/js.R

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,9 @@ odin_js_wrapper_continuous <- function(res) {
116116
use_names = TRUE, return_statistics = FALSE) {
117117
t_js <- to_json_js(t, auto_unbox = FALSE)
118118
y_js <- to_json_js(y, auto_unbox = FALSE, null = "null")
119+
if (!is.null(tcrit)) {
120+
tcrit <- I(tcrit)
121+
}
119122
control <- list(atol = atol,
120123
rtol = rtol,
121124
tcrit = tcrit,

inst/js/dust.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

inst/js/odin.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tests/testthat/test-run-interpolation.R

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,7 @@ test_that_odin("linear", {
176176
expect_error(mod$run(c(tt, max(tp) + 1)),
177177
"Integration times do not span interpolation range")
178178

179+
skip_for_target("js", "has better tcrit support")
179180
expect_error(mod$run(tt, tcrit = 3),
180181
"Interpolation failed as .+ is out of range")
181182
})

0 commit comments

Comments
 (0)