libgit2 / libgit2/libgit2sharp
CanClone Failed to send request: the operation timed out
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 3.5k
- Forks
- 925
- PR merge metrics
- No merged PRs in 30d
Description
I downloaded the code to run the clone method in the unit test natively, and an exception occurred
Failed to send request: the operation timed out
In LibGit2Sharp.Core.Ensure.HandleError(Int32 result) in F:\myTrialProjects\netcore\LibGit2Sharp\LibGit2Sharp\Core\Ensure.cs: line 154
In LibGit2Sharp.Core.Ensure.ZeroResult(Int32 result) in F:\myTrialProjects\netcore\LibGit2Sharp\LibGit2Sharp\Core\Ensure.cs: line 172
In LibGit2Sharp.Core.Proxy.Git_clone(url String, the String workdir, GitCloneOptions & opts) in F:\myTrialProjects\netcore\LibGit2Sharp\LibGit2Sharp\Core\Proxy in cs: line 276
In LibGit2Sharp.Repository.Clone(String sourceUrl, String workdirPath, CloneOptions options) in F:\myTrialProjects\netcore\LibGit2Sharp\LibGit2Sharp\Repository of cs: line 793
In LibGit2Sharp.Repository.Clone (String sourceUrl, String workdirPath) in F:\myTrialProjects\netcore\LibGit2Sharp\LibGit2Sharp\Repository of cs: line 727
In LibGit2Sharp.Tests.CloneFixture.CanClone(String url) in F:\myTrialProjects\netcore\LibGit2Sharp\LibGit2Sharp Tests\CloneFixture cs: in line 25
My computer os is win10 64bit.
I am looking forward to your help and Suggestions so that I can solve this problem.
The code I ran on my centos 7.5 virtual machine was successful,I installed libgit2 and dotnet build console ,Why doesn't Windows work?
var co = new CloneOptions();
CredentialsHandler credHandler = (_url, _user, _cred) => new UsernamePasswordCredentials { Username = "030586", Password = "12345678" };
co.CredentialsProvider = credHandler;
Repository.Clone("http://git.xxxx.com/030586/aaa-test", @"aaatest",co);
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with LibGit2Sharp.Tests/CloneFixture.cs at CanClone (line 25), then trace Repository.Clone through Core/Ensure.cs (lines 154 and 172) and Proxy.Git_clone (line 276). Compare the Windows 10 timeout with the successful CentOS 7.5 run; done means identifying and documenting the Windows-specific cause or verifying a fix.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp, git
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100