# HG changeset patch # User Marcin Kuzminski # Date 1350498745 -7200 # Node ID f3b913b76be126b8a90bcc7ab8945f606cc291bf # Parent 0ebdd15de1d89632a34edcdddc52bc7e9e160fdb Calculate file history always from latest changeset to always show full history. When doing the calculation from a particular changeset git doesn't any records from parent changesets diff -r 0ebdd15de1d8 -r f3b913b76be1 rhodecode/controllers/files.py --- a/rhodecode/controllers/files.py Tue Oct 16 23:34:34 2012 +0200 +++ b/rhodecode/controllers/files.py Wed Oct 17 20:32:25 2012 +0200 @@ -153,9 +153,8 @@ c.file = c.changeset.get_node(f_path) if c.file.is_file(): - _hist = c.changeset.get_file_history(f_path) - c.file_history = self._get_node_history(c.changeset, f_path, - _hist) + _hist = c.rhodecode_repo.get_changeset().get_file_history(f_path) + c.file_history = self._get_node_history(None, f_path, _hist) c.authors = [] for a in set([x.author for x in _hist]): c.authors.append((h.email(a), h.person(a))) @@ -487,8 +486,12 @@ return render('files/file_diff.html') def _get_node_history(self, cs, f_path, changesets=None): + if cs is None: + # if we pass empty CS calculate history based on tip + cs = c.rhodecode_repo.get_changeset() if changesets is None: changesets = cs.get_file_history(f_path) + hist_l = [] changesets_group = ([], _("Changesets"))