Skip to content

Commit 473df4b

Browse files
Merge branch 'release/0.4.0'
2 parents 9d870c9 + 65440b3 commit 473df4b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+1283
-750
lines changed

.make/Makefile

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ R_NO_INIT := --no-init-file
5656
R_VERSION_STATUS := $(shell $(R_SCRIPT) -e "status <- tolower(R.version[['status']]); if (regexpr('unstable', status) != -1L) status <- 'devel'; cat(status)")
5757
R_VERSION_X_Y := $(shell $(R_SCRIPT) -e "cat(gsub('[.][0-9]+$$', '', getRversion()))")
5858
R_VERSION := $(shell $(R_SCRIPT) -e "cat(as.character(getRversion()))")
59+
R_VERSION_3_3_OR_NEWER := $(shell $(R_SCRIPT) -e "cat(getRversion() >= '3.3.0')")
5960
R_VERSION_FULL := $(R_VERSION)$(R_VERSION_STATUS)
6061
R_LIBS_USER_X := $(shell $(R_SCRIPT) -e "cat(.libPaths()[1])")
6162
R_INCLUDE := $(shell $(R_SCRIPT) -e "cat(R.home('include'))")
@@ -79,6 +80,16 @@ GIT_COMMIT := $(shell $(GIT) log -1 --format="%h")
7980
R_LIBS_BRANCH := $(CURDIR)/.R/$(GIT_BRANCH)
8081

8182

83+
# Asserts proper Windows toolchain in R (>= 3.3.0)
84+
ifeq ($(OS), Windows_NT)
85+
ifeq ($(R_VERSION_3_3_OR_NEWER), TRUE)
86+
ifndef BINPREF
87+
$(error R (>= 3.3.0) on Windows: BINPREF not set)
88+
endif
89+
endif
90+
endif
91+
92+
8293
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
8394
# Main
8495
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
@@ -123,6 +134,7 @@ debug:
123134
@echo R_RD4PDF=\'$(R_RD4PDF)\'
124135
@echo
125136
@echo R_CRAN_OUTDIR=\'$(R_CRAN_OUTDIR)\'
137+
@echo R_VERSION_3_3_OR_NEWER=\'$(R_VERSION_3_3_OR_NEWER)\'
126138
@echo
127139

128140

@@ -326,6 +338,12 @@ $(R_OUTDIR)/vigns: install
326338
vignettes: $(R_OUTDIR)/vigns
327339

328340

341+
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
342+
# Static code validation etc
343+
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
344+
lint:
345+
$(R_SCRIPT) -e "library(lintr); lint_package(linters = with_defaults(commented_code_linter = NULL, closed_curly_linter = closed_curly_linter(allow_single_line = TRUE), open_curly_linter = open_curly_linter(allow_single_line = TRUE)))"
346+
329347
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
330348
# Run package tests
331349
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

.travis.yml

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,6 @@ matrix:
2424
r: oldrel
2525
- os: linux
2626
r: release
27-
r_github_packages:
28-
- jimhester/covr
29-
after_success:
30-
- Rscript -e 'covr::codecov(quiet=FALSE)'
31-
env:
32-
- NB='w/ covr' ## Just a label
3327
- os: linux
3428
r: devel
3529
- os: linux
@@ -38,14 +32,24 @@ matrix:
3832
- NB='w/ batchtools devel' ## Just a label
3933
- os: osx
4034
r: oldrel
41-
r_github_packages:
42-
- HenrikBengtsson/globals
43-
- HenrikBengtsson/future
4435
- os: osx
4536
r: release
37+
- os: linux
38+
r: release
4639
r_github_packages:
47-
- HenrikBengtsson/globals
48-
- HenrikBengtsson/future
40+
- jimhester/covr
41+
r_check_args: --no-codoc --no-examples --no-tests --ignore-vignettes
42+
after_success:
43+
- Rscript -e 'covr::codecov(quiet=FALSE)'
44+
env: NB='w/ covr' ## Just a label
45+
- os: linux
46+
r: release
47+
r_github_packages:
48+
- jimhester/lintr
49+
r_check_args: --no-codoc --no-examples --no-tests --ignore-vignettes
50+
after_success:
51+
- Rscript -e 'library(lintr); lint_package(linters = with_defaults(commented_code_linter = NULL, closed_curly_linter = closed_curly_linter(allow_single_line = TRUE), open_curly_linter = open_curly_linter(allow_single_line = TRUE)))'
52+
env: NB='w/ lintr' ## Just a label
4953

5054
before_install:
5155
- Rscript -e 'c(physical = parallel::detectCores(logical = FALSE), logical = parallel::detectCores())'

DESCRIPTION

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
Package: future.batchtools
2-
Version: 0.3.0
2+
Version: 0.4.0
33
Depends:
44
R (>= 3.2.0),
55
future (>= 1.4.0)
66
Imports:
7-
batchtools (>= 0.9.2),
8-
R.utils
7+
batchtools (>= 0.9.3)
98
Suggests:
109
listenv,
1110
markdown,

NAMESPACE

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ S3method(value,BatchtoolsFuture)
1313
export("%resources%")
1414
export(BatchtoolsFuture)
1515
export(BatchtoolsFutureError)
16+
export(batchtools_custom)
1617
export(batchtools_interactive)
1718
export(batchtools_local)
1819
export(batchtools_lsf)
@@ -26,11 +27,6 @@ export(loggedError)
2627
export(loggedOutput)
2728
export(status)
2829
export(value)
29-
importFrom(R.utils,isDirectory)
30-
importFrom(R.utils,isFile)
31-
importFrom(R.utils,mkdirs)
32-
importFrom(R.utils,removeDirectory)
33-
importFrom(R.utils,tempvar)
3430
importFrom(batchtools,batchExport)
3531
importFrom(batchtools,batchMap)
3632
importFrom(batchtools,clearRegistry)
@@ -41,6 +37,7 @@ importFrom(batchtools,loadResult)
4137
importFrom(batchtools,makeClusterFunctionsInteractive)
4238
importFrom(batchtools,makeClusterFunctionsLSF)
4339
importFrom(batchtools,makeClusterFunctionsMulticore)
40+
importFrom(batchtools,makeClusterFunctionsOpenLava)
4441
importFrom(batchtools,makeClusterFunctionsSGE)
4542
importFrom(batchtools,makeClusterFunctionsSlurm)
4643
importFrom(batchtools,makeClusterFunctionsTORQUE)

NEWS

Lines changed: 45 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,63 @@
11
Package: future.batchtools
22
==========================
33

4+
Version: 0.4.0 [2017-05-16]
5+
6+
NEW FEATURES:
7+
8+
o Added batchtools_custom() for specifying batchtools futures using any type
9+
of batchtools cluster functions.
10+
11+
o batchtools_template(pathname = NULL, type = <type>) now relies on the
12+
batchtools package for locating the <type> template file.
13+
14+
o nbrOfWorkers() for batchtools futures now defaults to +Inf unless the
15+
evaluator's 'workers' or 'cluster.functions' specify something else.
16+
17+
o Renamed argument 'pathname' to 'template' for batchtools_<tmpl>() functions.
18+
19+
BUG FIXES:
20+
21+
o Under plan(batchjobs_*), when being created futures would produce an error
22+
on "all(is.finite(workers)) is not TRUE" due to an outdated sanity check.
23+
24+
SOFTWARE QUALITY:
25+
26+
o TESTS: Added test of future_lapply() for batchtools backends.
27+
28+
o TESTS: Added optional tests for batchjobs_* HPC schedulers listed in
29+
environment variable 'R_FUTURE_TESTS_STRATEGIES'.
30+
31+
CODE REFACTORING:
32+
33+
o CLEANUP: Package no longer depends on R.utils.
34+
35+
436
Version: 0.3.0 [2017-03-19]
537

638
NEW FEATURES:
739

840
o The number of jobs one can add to the queues of HPC schedulers is in
9-
principle unlimited, which is why the number of available workers for
10-
such batchtools_* backends is reported as +Inf. However, as the number
11-
of workers is used by future_lapply() to decide how many futures should
12-
be used to best partition the elements, this means that future_lapply()
13-
will always use one future per element. Because of this, it is now
14-
possible to specify plan(batchtools_*, workers = n) where 'n' is the
15-
target number of workers.
41+
principle unlimited, which is why the number of available workers for such
42+
batchtools_* backends is reported as +Inf. However, as the number of
43+
workers is used by future_lapply() to decide how many futures should be used
44+
to best partition the elements, this means that future_lapply() will always
45+
use one future per element. Because of this, it is now possible to specify
46+
plan(batchtools_*, workers = n) where 'n' is the target number of workers.
1647

1748

1849
Version: 0.2.0 [2017-02-23]
1950

2051
GLOBALS:
2152

22-
o batchtools (>= 0.9.2) now supports exporting objects with
23-
any type of names (previously only possible if they mapped to
24-
to strictly valid filenames). This allowed me to avoid lots of
25-
internal workaround code encoding and decoding globals.
53+
o batchtools (>= 0.9.2) now supports exporting objects with any type of names
54+
(previously only possible if they mapped to to strictly valid filenames).
55+
This allowed me to avoid lots of internal workaround code encoding and
56+
decoding globals.
2657

2758

2859
Version: 0.1.0 [2017-02-11]
2960

30-
o Package created by porting the code of future.BatchJobs.
31-
This version passes 'R CMD check --as-cran' with all OK
32-
after a minimial amount of adjustments to the ported code.
61+
o Package created by porting the code of future.BatchJobs. This version passes
62+
'R CMD check --as-cran' with all OK after a minimial amount of adjustments
63+
to the ported code.

0 commit comments

Comments
 (0)