Skip to content

Commit

Permalink
Merge pull request #125 from terrytangyuan/version-check
Browse files Browse the repository at this point in the history
Update version check for R package
  • Loading branch information
yongtang authored Mar 1, 2019
2 parents 8b7a7d3 + ecedb99 commit f427619
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion R-package/DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ Description: Interface to 'TensorFlow IO', Datasets and filesystem extensions ma
License: Apache License 2.0
URL: https://github.com/tensorflow/io
BugReports: https://github.com/tensorflow/io/issues
SystemRequirements: TensorFlow >= 1.4 (https://www.tensorflow.org/)
SystemRequirements: TensorFlow >= 1.13.0 (https://www.tensorflow.org/) and TensorFlow IO >= 0.4.0 (https://github.com/tensorflow/io)
Encoding: UTF-8
LazyData: true
Depends:
Expand Down
6 changes: 3 additions & 3 deletions R-package/R/package.R
Original file line number Diff line number Diff line change
Expand Up @@ -49,11 +49,11 @@ tfio_module_not_available_message <- function() {

check_tensorflow_version <- function(displayed_warning) {
current_tf_ver <- tf_version()
required_ver <- "1.12.0"
if (current_tf_ver != required_ver) {
min_ver <- "1.13.0"
if (current_tf_ver < min_ver) {
if (!displayed_warning) {
packageStartupMessage(
"tfio requires TensorFlow version == ", required_ver, " ",
"tfio requires TensorFlow version >= ", min_ver, " ",
"(you are currently running version ", current_tf_ver, ").\n")
displayed_warning <<- TRUE
}
Expand Down

0 comments on commit f427619

Please sign in to comment.