Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pdm list 打印出的信息 有些反直觉 #3224

Closed
shifenhutu opened this issue Oct 20, 2024 · 3 comments
Closed

pdm list 打印出的信息 有些反直觉 #3224

shifenhutu opened this issue Oct 20, 2024 · 3 comments
Labels
⭐ enhancement Improvements for existing features

Comments

@shifenhutu
Copy link

pyproject.toml

[project]
name = "flow-111"
version = "0.1.0"
description = "Default template for PDM package"

dependencies = [
    "curl-cffi>=0.7.3",
    "pydantic>=2.9.2",
    "jupyterlab>=4.2.5",
    "plotly>=5.24.1",
    "pandas>=2.2.3",
]
requires-python = "==3.12.*"
readme = "README.md"
license = {text = "MIT"}


[tool.pdm]
distribution = false

情况描述

当我使用 pdm list 的时候,列出了 几十个包,太多了, 其实我只想看看 我现在安装的包的版本号

image

期待的解决方案

pdm list 只检测出 在我 pyproject.toml 文件 的 dependencies配置里 的包 和它们的版本号, 可以通过添加参数 --include-sub 查看 包含子包的情况

参考

#3219

@shifenhutu shifenhutu added the ⭐ enhancement Improvements for existing features label Oct 20, 2024
@shifenhutu
Copy link
Author

shifenhutu commented Oct 20, 2024

pdm outdated 我觉得也可以这样处理 , 默认 只检测 dependencies 配置里 的包

@shifenhutu
Copy link
Author

pdm 很多命令, 默认情况,建议只作用于 dependencies 配置里 的包, 可通过添加额外参数 --include-sub 来 包含 子包

@frostming
Copy link
Collaborator

No, that is different, pdm list only cares about "what packages you have installed" and not about what dependencies you specified in the project. Like you can initialize an empty project with an existing venv and run pdm list to list what is installed in that venv. This has the same function as pip list or conda list.

@frostming frostming closed this as not planned Won't fix, can't repro, duplicate, stale Oct 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⭐ enhancement Improvements for existing features
Projects
None yet
Development

No branches or pull requests

2 participants