Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Crash creating exploded topics

未关闭 适合新手
#7 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
62/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
停滞
技术栈
git, python
领域
cli

调研方向

从 git_explode/exploder.py 开始,重点查看 prepare_cherrypick_base 和 checkout_new_dependent_topic,并使用 traceback 和 dependent-topic log 作为复现路径。调查为什么在访问 deps 的第一个元素时,deps 是一个 dict_keys 对象,然后重新运行 exploded-topics scenario,并确认 dependent topics 能够在不发生崩溃的情况下创建。

由索引模型根据 Issue 内容生成。

描述

Once it did finish analysis, it crashed:

Jul 26 18:14:52 DEBUG  Exploding 0e1526a1 ARGH
git checkout -q -b topic1 main
git cherry-pick 0e1526a1dfed84807adc366ce0278a0cafb008ba
Jul 26 18:14:52 DEBUG    Assigned topic1 to 0e1526a1dfed84807adc366ce0278a0cafb008ba
Jul 26 18:14:52 DEBUG  - cherry-picked 0e1526a1 as e0b57735 (ARGH)
Jul 26 18:14:52 DEBUG  Exploding 5228ebef Speed up codeowner glob test by using ruby, not bash
git checkout -q -b topic2 main
git cherry-pick 5228ebef053318e574120ddae698a6e831fb61d7
Jul 26 18:14:53 DEBUG    Assigned topic2 to 5228ebef053318e574120ddae698a6e831fb61d7
Jul 26 18:14:53 DEBUG  - cherry-picked 5228ebef as 8269a2b4 (Speed up codeowner glob test by using ruby, not bash)
Jul 26 18:14:53 DEBUG  Exploding dfba4974 Add many acronyms to config/initializers/inflections.rb
git checkout -q -b topic3 main
git cherry-pick dfba4974279cbabb35c0aa0dde2a8ab796c09fd4
Jul 26 18:14:53 DEBUG    Assigned topic3 to dfba4974279cbabb35c0aa0dde2a8ab796c09fd4
Jul 26 18:14:53 DEBUG  - cherry-picked dfba4974 as 5b1d79d9 (Add many acronyms to config/initializers/inflections.rb)
Jul 26 18:14:53 DEBUG  + pushed to queue: 41307936 inflect JSON and YAML correctly
Jul 26 18:14:53 DEBUG  + pushed to queue: 1f590ec0 inflect HC as a non-acronym
Jul 26 18:14:53 DEBUG  + pushed to queue: c421f3e1 inflect CIA correctly
Jul 26 18:14:53 DEBUG  + pushed to queue: 560f874e inflect API as a non-acronym
Jul 26 18:14:53 DEBUG  Exploding 560f874e inflect API as a non-acronym
Jul 26 18:14:53 DEBUG    deps: dfba4974
git cherry-pick 560f874e8124d9cad6ea55814bdb519f0d8da719
Jul 26 18:14:53 DEBUG    Unassigned topic3 from dfba4974279cbabb35c0aa0dde2a8ab796c09fd4
Jul 26 18:14:53 DEBUG    Assigned topic3 to 560f874e8124d9cad6ea55814bdb519f0d8da719
Jul 26 18:14:53 DEBUG  - cherry-picked 560f874e as 11b71822 (inflect API as a non-acronym)
Jul 26 18:14:53 DEBUG  Exploding c421f3e1 inflect CIA correctly
Jul 26 18:14:53 DEBUG    deps: dfba4974
Jul 26 18:14:53 DEBUG    Assigned topic4 to dfba4974279cbabb35c0aa0dde2a8ab796c09fd4
Traceback (most recent call last):
  File "/Users/ryan.davis/Library/Python/3.11/bin/git-explode", line 10, in <module>
    sys.exit(run())
             ^^^^^
  File "/Users/ryan.davis/Code/git/aspiers/git-explode/git_explode/cli.py", line 71, in run
    main(sys.argv[1:])
  File "/Users/ryan.davis/Code/git/aspiers/git-explode/git_explode/cli.py", line 67, in main
    exploder.run()
  File "/Users/ryan.davis/Code/git/aspiers/git-explode/git_explode/exploder.py", line 40, in run
    self.explode(commits, deps_from, deps_on)
  File "/Users/ryan.davis/Code/git/aspiers/git-explode/git_explode/exploder.py", line 107, in explode
    self.prepare_cherrypick_base(sha, deps, commits)
  File "/Users/ryan.davis/Code/git/aspiers/git-explode/git_explode/exploder.py", line 130, in prepare_cherrypick_base
    self.checkout_new_dependent_topic(deps)
  File "/Users/ryan.davis/Code/git/aspiers/git-explode/git_explode/exploder.py", line 189, in checkout_new_dependent_topic
    base = self.exploded[deps[0]]
                         ~~~~^^^
TypeError: 'dict_keys' object is not subscriptable
主要语言
Python
星标
60
派生
3
PR 合并指标
30 天内没有已合并 PR

环境准备

  • 没有 Dockerfile 或 Docker Compose 文件
  • 没有 Pull Request 模板
  • 阅读贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

aspiers/git-explode 的其他 Issue

查看 aspiers/git-explode 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。