posit-dev / positron

Positron, a next-generation data science IDE
Other
1.53k stars 43 forks source link

Provide a way to see loaded packages (R) and modules (Python) #1369

Open jmcphers opened 9 months ago

jmcphers commented 9 months ago

via @hadley:

should the environment pane include a list of attached packages? that is a very important part of your current computing environment

https://positpbc.slack.com/archives/C05M2EZCPGR/p1695325731073809

This is a good point. For a while, the Environment pane also included a list of loaded Python modules. We now suppress these, but whatever mechanism we use to show attached R packages could also be used to show loaded Python modules.

hadley commented 9 months ago

This gets a bit more tricky if Environment becomes Variables, but there's probably something useful that's still much lighter than the RStudio packages panes.

kmasiello commented 9 months ago

Would also like to see a nice representation of renv or venv states in this pane. Examples: make it very clear when you're working within a venv or renv-project make renv::status readily viewable show me what index-url or options("repos") sources I'm using

hadley commented 9 months ago

@kmasiello I think that's worth filing as a separate issue as it's a fairly big topic and different to just listing which packages are attached.

seeM commented 8 months ago

For reference, useful suggestions from @petetronic in the linked Slack thread above:

We have "kinds" to group environment variables, currently we have "Data", "Values", and "Functions". Adding a "Imported Modules" kind would be trivial (or whatever name we finalize for these), would that be a satisfactory light treatment?

While you can remove this grouping in the environment display, we could still special case them so they were not interleaved with variables if we needed.

Perhaps we could also show basic information about the module such as version.

juliasilge commented 3 months ago

In our private beta, there is some strong interest in something like the RStudio packages pane: https://github.com/posit-dev/positron-beta/discussions/34

jennybc commented 3 months ago

A big takeaway for me from the positron-beta thread is that some folks use RStudio's Packages pane as a very important entry point for accessing help. I have never been a big user of the Packages pane myself and I always assumed that, for those who do use it, it was about installing or updating packages.

That being said, I wonder if these are two separate issues? I think this issue is about seeing loaded packages, whereas RStudio's Packages pane is about seeing installed packages.