1. Sebastian Sebastian
  2. scm-manager


Issue #354 resolved

Default "Commits" view of Mercurial repository is not showing all commits

Anonymous created an issue

I have a Hg repository that I have imported into scm-manager. When I select that Repository from the repo list, and choose to view "Commits", it shows me all the commits up to the time I first imported the repository, and shows the last commit just before I imported as the "tip". If I then select the "default" branch from the Branch dropdown, it shows me all the commits, including ones since the import, and tip is the last commit on the default branch. We only have one branch on this repo (the default branch), so why doesn't the initial view of commits show all the commits on this branch? If I view the history in TortoiseHg, it shows all the commits, and all of them as being on the default branch.

Comments (12)

  1. Sebastian Sebastian repo owner
    • changed status to open

    This looks like a caching problem. The default view for commits, is a combined view of all branches. Have you done each push over http? Or do you have made a push directly to the directory on the server? Is the cache cleared when you push new changesets?

  2. Ian Duncanson

    At the moment, all the commits are made directly on the server. We are synching changesets from another SCM system (Sourcegear Vault), the server for which is on the same machine as scm-manager. So whenever there is a commit to Vault, we detect this and do a local commit directly to the scm-manager Hg repository. Not quite sure what you mean when you ask whether the cache is cleared when we push changesets. Which cache are you referring to?

  3. Sebastian Sebastian repo owner

    SCM-Manager uses a cache for the commit view. This cache is cleared, if you push new changesets to the repository over http. If you push directly to the folder you will bypass the cache clear hook. Bypass the cache clear will result in old data views in the ui. Could you do your sync over http?

  4. Ian Duncanson

    OK, I see. I have changed our arrangement so I commit to a repository on the server, and then push this via http to the scm-manager repository on the same machine. Thanks for your help.

  5. Ian Duncanson


    This might be a silly question, but how do you create new Ecmascript scripts for the script plugin (the Groove script is what I want, but we don't have Groove on our scm machine)? I can run the sample Ecmascript to list recent changesets, but can't seem to create new ones. And can these scripts be invoked in any way other than through the Developer Console - can they be invoked from outside the web interface (through one of the apis perhaps)?

    Regards, Ian

  6. Sebastian Sebastian repo owner

    You do not need to install groovy on your machine. The script plugins installs groovy in the classapth of scm-manager. If you want to execute a script from outside of scm-manager, you can use the rest endpoint of the script plugin. To use this you have to create the script some where in your fs and send it to the endpoint. Here is a example with curl:

    curl -XPOST -H "Content-Type: application/x-groovy" -u scmadmin:scmadmin http://localhost:8080/scm/api/rest/plugins/script -d @myscript.groovy
  7. Log in to comment