500 errors when opening a file or the commit list when mailmap is used.

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

問題

When the repository has a .mailmap file in its root directory, opening the commit list or a file fails with a 500 error. Additionally, the following appears in the atlassian-bitbucket.log:

  • on Linux or Mac OS:

    An error occurred while executing an external process: '/usr/bin/git rev-list --format=%H%x02%h%x02%P%x02%p%x02%aN%x02%aE%x02%at%n%B%n%x03 -1 refs/heads/master -- mailmap' exited with code 139
    com.atlassian.bitbucket.exception.ServerException: An error occurred while executing an external process: '/usr/bin/git rev-list --format=%H%x02%h%x02%P%x02%p%x02%aN%x02%aE%x02%at%n%B%n%x03 -1 refs/heads/master -- mailmap' exited with code 139
    	at com.atlassian.bitbucket.internal.scm.git.GitCommandExitHandler.evaluateThrowable(GitCommandExitHandler.java:120) ~[na:na]
    	at com.atlassian.bitbucket.internal.scm.git.GitCommandExitHandler.onError(GitCommandExitHandler.java:163) ~[na:na]
  • or on Windows:

    An error occurred while executing an external process: 'C:\Program Files (x86)\Git\cmd\git.exe rev-list --format=%H%x02%h%x02%P%x02%p%x02%aN%x02%aE%x02%at%n%B%n%x03 -1 refs/heads/master -- .mailmap' exited with code 255
    com.atlassian.bitbucket.exception.ServerException: An error occurred while executing an external process: 'C:\Program Files (x86)\Git\cmd\git.exe rev-list --format=%H%x02%h%x02%P%x02%p%x02%aN%x02%aE%x02%at%n%B%n%x03 -1 refs/heads/master -- .mailmap' exited with code 255
    	at com.atlassian.bitbucket.internal.scm.git.GitCommandExitHandler.evaluateThrowable(GitCommandExitHandler.java:120) ~[na:na]
    	at com.atlassian.bitbucket.internal.scm.git.GitCommandExitHandler.onError(GitCommandExitHandler.java:163) ~[na:na]

原因

This is related to a bug in Git from 1.8.2 to 1.8.4 (on Linux or Windows), which is described in more details in BSERV-3891.

回避策

次のいずれかを実行します。

  • to fix the issue on all the repositories hosted in Bitbucket Server, downgrade to a version of Git or msysgit prior to 1.8.2.
  • or, to fix the issue only for the current repository, edit the .mailmap on the repository's default branch (usually master) to include a newline at the end of the file, then commit and push the change to Bitbucket Server: 

    $ git fetch origin
    $ git checkout origin/master
    $ echo -e "\n" >> .mailmap
    $ git commit -m"fix .mailmap line ending" -- .mailmap
    $ git push origin HEAD:master

最終更新日 2016 年 5 月 25 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.