Project

General

Profile

Weird thing happens when fetching repository commits with a cronjob

Added by Stan Thorovsky about 13 years ago

Redmine version: 1.1

Because we want to reference issues in Git commit messages I've set up a cronjob to fetch repository commits:

rake -f /var/www/redmine-1.1/Rakefile redmine:fetch_changesets RAILS_ENV="production" 

so that we can have issue pages display these as comments.

Cronjob works, commits get fetched. Issues comments do get updated but in a strange fashion:

in "Associated revisions" every revision appears twice - once attributed to a real commiter and then immediately once more - now attributed to a user that is not a member of that particular project and does not have rights to commit or even view repositories in any of the projects.

What is happening?


Replies (5)

RE: Weird thing happens when fetching repository commits with a cronjob - Added by Felix Schäfer about 13 years ago

Can you reproduce this with a new git repository on a new project, preferably even on a clean redmine installation?

RE: Weird thing happens when fetching repository commits with a cronjob - Added by Stan Thorovsky about 13 years ago

No, this only happens for that specific project. On the same installation other projects get updated correctly.

RE: Weird thing happens when fetching repository commits with a cronjob - Added by Felix Schäfer about 13 years ago

Do you have a repository that is associated to 2 projects in your Redmine?

RE: Weird thing happens when fetching repository commits with a cronjob - Added by Stan Thorovsky about 13 years ago

That's a good question because the answer is "yes" - the repository for this project is shared with 1 of its sub-projects. Is this a reason for the weird attribution of comments?

RE: Weird thing happens when fetching repository commits with a cronjob - Added by Felix Schäfer about 13 years ago

Well, if the same repository is associated to 2 projects, if you reference issues from the commit message, there will be a link to each of the two projects created for said issue. I'd guess the entries that are double do point to both projects?

    (1-5/5)