BAAQMD / BAAQMD/tbltools

Importing `qtytools::total` leads to error

Open
#28 2 comments 0 reactions 0 assignees View on GitHub
check
Dominant language
R
Stars
1
Forks
0
PR merge metrics
No merged PRs in 30d

Description

Function [pulll_total](https://github.com/BAAQMD/tbltools/blob/master/R/pull_total.R#L10) uses function `total` from package `qtytools`. But it does not `@importFrom` qtytools, and the DESCRIPTION file does not Import/Suggest/Depend upon `qtytools`. This leads to an error when running R CMD CHECK: `tbltools` needs `qtytools` to run, and so the package should explicitly declare that dependency.

However, when I add `@importFrom qtytools total` and add `qtytools` to the `Import` section of the DESCRIPTION file and run R CMD CHECK I get this error:
```
Warning in (function (dep_name, dep_ver = "*") :
Dependency package 'qtytools' not available.
Error: Dependency package(s) 'qtytools' not available.
```

This might be because `qtytools` actually lists `tbltools` in the `Depends` section of the DESCRIPTION file ([link](https://github.com/BAAQMD/qtytools/blob/master/DESCRIPTION#L14)). That is, there seems to be a circular dependency between `qtytools` and `tbltools`. It is not explicity right now. But making it explicit seems to result in an error.

Contributor guide

No contributing guide indexed for this repository

Research direction

Inspect R/pull_total.R at the referenced function and both packages' DESCRIPTION files, then run R CMD CHECK to reproduce the missing-dependency and circular-dependency errors. Determine a dependency arrangement that lets tbltools use qtytools without an invalid cycle; done means the package declares its dependencies correctly and R CMD CHECK passes.

Written by the indexing model from the issue text.

Assessment

Tech stack
r
Domain
build-system
Issue type
Bug
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.