Skip to content

Conversation

@mduncans
Copy link

…t package

I had an issue with a broken binary of data.table in my package, but I wasn't sure where it was coming from. rv tree can help, but I wanted a --package data.table flag to filter the tree to show me how it was being introduced. This PR adds that functionality

mattsmith@Mac reportifyr % rv tree | wc
    1454   15038  156127
mattsmith@Mac reportifyr % rv tree --package data.table
▶ reportifyr [ignored]
└─ flextable [version: 0.9.9, source: https://packagemanager.posit.co/cran/latest, type: source]
  └─ data.table [version: 1.17.8, source: https://packagemanager.posit.co/cran/latest, type: binary]
mattsmith@Mac reportifyr % rv tree --package systemfonts
▶ devtools [version: 2.4.5, source: https://packagemanager.posit.co/cran/latest, type: binary]
└─ pkgdown [version: 2.1.3, source: https://packagemanager.posit.co/cran/latest, type: binary]
  └─ ragg [version: 1.4.0, source: https://packagemanager.posit.co/cran/latest, type: binary]
    ├─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]
    └─ textshaping [version: 1.0.1, source: https://packagemanager.posit.co/cran/latest, type: binary]
      └─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]

▶ reportifyr [ignored]
├─ flextable [version: 0.9.9, source: https://packagemanager.posit.co/cran/latest, type: source]
│ ├─ ragg [version: 1.4.0, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ │ ├─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ │ └─ textshaping [version: 1.0.1, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ │   └─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ ├─ officer [version: 0.6.10, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ │ └─ ragg [version: 1.4.0, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ │   ├─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ │   └─ textshaping [version: 1.0.1, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ │     └─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]
│ └─ gdtools [version: 0.4.2, source: https://packagemanager.posit.co/cran/latest, type: source]
│   └─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]
└─ officer [version: 0.6.10, source: https://packagemanager.posit.co/cran/latest, type: binary]
  └─ ragg [version: 1.4.0, source: https://packagemanager.posit.co/cran/latest, type: binary]
    ├─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]
    └─ textshaping [version: 1.0.1, source: https://packagemanager.posit.co/cran/latest, type: binary]
      └─ systemfonts [version: 1.2.3, source: https://packagemanager.posit.co/cran/latest, type: binary]

@mduncans mduncans requested a review from Keats July 16, 2025 10:24
Copy link
Collaborator

@Keats Keats left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Without reviewing the actual code.

I think what you want here is actually --invert.
Eg rv tree --invert=data.table that would put data.table at the top and then a tree of everything depending on it. We talked about adding --invert before, that would be a good time

```

## JSON Output Support
All tree structures implement `Serialize` for JSON output, enabling programmatic consumption of dependency tree data. No newline at end of file
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are we going to commit all the Claude stuff? Most of this seem to be thing the llm should pick up anyway from looking at the structs and might be out of date

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

from the claude code best practices the ai-references should be used to help guide it and improve its understanding of where to find stuff so it doesn't search so much. but to your comment below, they need to be auditted very carefully

**Key Fields:**
- `name`: Package name
- `version`: Package version (if resolved)
- `source`: Where the package comes from (lockfile, repository, git, etc.)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See that's wrong there, a package never comes from the lockfile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants