Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in
  • S s2dverification
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 65
    • Issues 65
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 7
    • Merge requests 7
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Earth SciencesEarth Sciences
  • s2dverification
  • Issues
  • #250
Closed
Open
Issue created Sep 30, 2020 by aho@ahoMaintainer

Load: new cdo version name causes error

This issue is reported by the external users. The email is below:

    I am writing to you for an issue with the Load function that came up after updating our server to Ubuntu 20.04. R and the R libraries have also been updated to the latest versions. 

I am actually using the CSTools::CST_Load function that is a wrapper of s2dverification::Load. After the Load function is called I obtain the error you see in the attached screenshot. Enclosed you will also find the simple script I use to load the data)

===================

after my colleague Silvia Terzago wrote you regarding a problem with s2dverification::Load (and CSTools::CST_Load function), I investigated a bit the issue and found the problem.
The problem is at line 209 of Utils.R (of s2dverification) where cdo is interrogated for its version.
In fact our cdo responds with "1.9.9rc1" and this is not something that as.numeric_version can digest.

The solution is changing the code in Utils.R (line 209) to

      cdo_version <- strsplit(suppressWarnings(system2("cdo", args = '-V', stderr = TRUE))[[1]], ' ')[[1]][5]

      cdo_version <- as.numeric_version(unlist(strsplit(cdo_version, "[A-Za-z]", fixed=FALSE))[[1]])
Assignee
Assign to
Time tracking