Modify

Opened 6 years ago

Closed 6 years ago

#3410 closed defect (fixed)

If caching is activated and the first commit is empty diff_tree() fails

Reported by: zany Owned by: hvr
Priority: high Component: GitPlugin
Severity: critical Keywords:
Cc: Trac Release: 0.11

Description

If caching is activated (cached_repository = true) and the first commit is empty

diff_tree() fails when trying to remove the first output line:

Trac detected an internal error:
IndexError: list index out of range

Fix: in PyGIT.py line 636:

if tree1 is None and len(lines) > 0:

Attachments (2)

gitplugin_empty-commit-fix.txt (501 bytes) - added by zany 6 years ago.
gitplugin_empty-commit-fix.patch (501 bytes) - added by zany 6 years ago.

Download all attachments as: .zip

Change History (4)

Changed 6 years ago by zany

Changed 6 years ago by zany

comment:1 Changed 6 years ago by zany

This is a dup of #2807

comment:2 Changed 6 years ago by hvr

  • Resolution set to fixed
  • Status changed from new to closed

(In [4148]) GitPlugin: make diff_tree handle empty changesets (fixes #2807 and #3410)

Add Comment

Modify Ticket

Action
as closed The owner will remain hvr.
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.