You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

如何通过setup.cfg为Python包新增entry points?

更新开发模式下的entry points(setup.cfg配置)
  • 确认你已经在setup.cfg的[options.entry_points]区块中添加好新的console_scripts条目(如你提供的示例内容)
  • 在项目根目录下重新执行开发安装命令:
    pip install -e .
    
    这个命令本身就等效于旧的python setup.py develop,它会重新解析setup.cfg的配置,自动更新已安装的开发版包,包含新增的entry points
  • 验证:直接在终端运行新的entry point命令(比如new_entry_point),确认能正常调用对应的脚本逻辑

内容的提问来源于stack exchange,提问作者Lasse Meixner

相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.08.14 06:55:24