libgit2 / libgit2/libgit2sharp

Exception During Rebase: No error message has been provided by the native library

未关闭
#1,698 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

主要语言
C#
星标
3.5k
派生
925
PR 合并指标
30 天内没有已合并 PR

描述

I've seen this happen a couple times out of a hundred, so it is difficult to reproduce. When it has happened, I've rebased successfully from the command-line without any conflicts; then when I re-run this it still fails.

Stack Trace

LibGit2Sharp.LibGit2SharpException: No error message has been provided by the native library
at LibGit2Sharp.Core.Ensure.HandleError(Int32 result)
at LibGit2Sharp.Core.Proxy.git_rebase_init(RepositoryHandle repo, AnnotatedCommitHandle branch, AnnotatedCommitHandle upstream, AnnotatedCommitHandle onto, GitRebaseOptions options)
at LibGit2Sharp.Rebase.Start(Branch branch, Branch upstream, Branch onto, Identity committer, RebaseOptions options)

Reproduction steps
var rebaseResult = repository.Rebase.Start(featureBranch, masterBranch, null, _getIdentity(repository), new RebaseOptions());
Expected behavior

A rebaseResult.Status

Actual behavior

An exception

Version of LibGit2Sharp (release number or SHA1)

0.26.0

Operating system(s) tested; .NET runtime tested

Windows 10

贡献指南

打开贡献指南

从这里开始

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

调研方向

从复现中的 Rebase.Start 调用开始,跟踪它经过 LibGit2Sharp.Rebase.Start、Core.Proxy.git_rebase_init 和 Core.Ensure.HandleError 的过程。在 Windows 10 上使用 LibGit2Sharp 0.26.0 和提供的分支参数进行复现,然后将 native 失败与预期的 rebaseResult.Status 进行比较。当间歇性情况得到解释,并且无需空错误异常即可处理时,即视为完成。

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

评估

技术栈
csharp, git
领域
devtools
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

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