[Rd] Consider getNamespaceVersion() returning a numeric_version

Dirk Eddelbuettel edd @end|ng |rom deb|@n@org
Thu Oct 17 15:00:01 CEST 2024


On 17 October 2024 at 13:42, Tim Taylor wrote:
| I mean the `numeric_version` object not a numeric (double/int). 
| Basically to protect me from myself I'd prefer not to have to remember 
| to wrap `getNamespaceVersion()` with `as.package_version()`.

That would be a breaking change. I suspect you would need to supply stronger
motivation.

Note that these days you can add arbitrary fields to DESCRIPTION so you
already can add a new field that you can the require to be a value from an
integer sequence (or a numeric if you prefer).

| I suspect a grep of CRAN may highlight others who are erroneously 
| comparing character objects rather than a comparison between a 
| `numeric_version` object and a character.

Sure but still a user-level bug though. Usually those get fixed them on that
side.

(And to be clear, I have nothing against your proposal per se and like it in
the abstract. I am just trying to help think through what it may entail.)

Dirk

-- 
dirk.eddelbuettel.com | @eddelbuettel | edd using debian.org



More information about the R-devel mailing list