Closed
Description
#547 implements a missing_package_linter()
which checks if all packages loaded by library()
, require()
, loadNamespace()
, and requireNamespace()
are installed.
Apart from that, we could also check the usage of ns::obj
and ns:::obj
as they also used to access objects in a namespace (provided by package).
We could implement a separate linter (as suggested at #547 (comment)) to check if
- The package
ns
inns::obj
andns:::obj
are installed. - The
obj
inns::obj
is exported from namespacens
. - The
obj
inns:::obj
exists in namespacens
.
While checking 1 does not load any new package, checking 2 and 3 might load the package being checked. I'm not sure if we allow loading extra packages from user code?
Metadata
Metadata
Assignees
Labels
No labels