isomorphic-git: Error when pulling after a commit has been made outside isomorphic-git

In the browser (Firefox latest stable), using <script src="bundle.umd.min.js"></script> where bundle.umd.min.js comes from node_modules/isomorphic-git/dist/ (i.e., latest on npm), I can successfully clone a repo from GitHub using isomorphic-git (woweee 🙌!):

        await git.clone({
          fs,
          dir: 'repo',
          url: 'https://cors-buster-tbgktfqyku.now.sh/github.com/fasiha/test-data',
          singleBranch: true,
          depth: 1
        });

Then outside isomorphic-git/browser I push another commit (e.g., I go to GitHub and edit a file and commit).

Then back in my isomorphic-git browser tab to git.pull but I can’t: running this in the JS Console:

git.pull({fs, dir: 'repo'}).then(x => console.log(x))

produces TypeError: e.committer is undefined in merge.js:65:2.

If I try to go a different route: I can run git.fetch successfully but git.merge in isomorphic-git tab fails with a different error.

I understand that only fast-forwards are allowed, but the remote repo on GitHub is only a commit ahead of that in isomorphic-git and should fast-forward.

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Comments: 16 (10 by maintainers)

Most upvoted comments

I’ll have to test this more thoroughly this week. I’ll figure it out, I promise. This is too basic and important a task to have not working!

So I tested this today with latest npm-published version, both with isogit CLI utility and browser, and everything worked as expected!