Env Variable to Auto-Name and Recognize __pycache__ As .__pycache__
还没有人认领这个 Issue。
- 主要语言
- Python
- 星标
- 77.2k
- 派生
- 35.9k
- PR 合并指标
- PR 指标待抓取
描述
Feature or enhancement
Proposal:
Introduce a Bash environment variable (PYTHON_PYCACHE_HIDDEN) that, when set, automatically names and recognizes the __pycache__ directory as .__pycache__. This change aims to improve directory cleanliness by making the __pycache__ directory hidden by default, reducing visual clutter in project directories.
The __pycache__ directory, often clutters project directories. While necessary for Python's efficient execution, it can be an eyesore, especially in larger projects. Making this directory hidden by default would: improve directory readability, maintain compiled functionality, and introduce optional visibility.
Bottom line, __pycache__ directory enhances Python's execution efficiency by storing compiled bytecode, but its contents are rarely useful for regular viewing, cluttering project directories unnecessarily.
Has this already been discussed elsewhere?
No response given
Links to previous discussion of this feature:
No response
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
调研方向
该 issue 未指定文件、测试或入口点。首先定位 CPython 对 pycache 目录命名和识别的处理方式,然后确定环境变量是如何处理的。完成的标准是:可选启用的 PYTHON_PYCACHE_HIDDEN 设置始终使用并识别 .pycache,且不会破坏已编译字节码的行为。
由索引模型根据 Issue 内容生成。
评估
- 技术栈
- python
- 领域
- operating-systems
- Issue 类型
- 功能
- 难度
- 5/5
- 预计耗时
- 一周以上
- 活跃度
- 停滞
- 描述清晰度
- 需要澄清
- 新手友好度
- 25/100