Skip to content
Prev 61734 / 63424 Next

numeric_version doesn't like numeric versions anymore?

Dear R devs,

I installed the recent devel R to test a package error when I intercept this warning when loading packages:

```
Warning in .make_numeric_version(x, strict, .standard_regexps()$valid_numeric_version) :
  invalid non-character version specification 'x' (type: double)
```

After a long debugging, I realize that `numeric_version` in base does not support numerical input x by default now. 

A reproducible example: 

R 4.4

```
Warning in .make_numeric_version(x, strict, .standard_regexps()$valid_numeric_version) :
  invalid non-character version specification 'x' (type: double)
[1] ?1.5?
```


R 4.3.1

```
[1] ?1.5?
```

According to help document, `strict=TRUE` should result in errors, then the 4.3 behavior was actually incorrect. According to pkgload maintainer, Kurt has sent him an email to fix this, suggesting this on-going change is intentional.
 
May I ask is there any benefit of changing the behavior?

Thanks,
- D