Modify

Opened 6 years ago

#13401 new defect

AttributeError: '_pygit2.Patch' object has no attribute 'status'

Reported by: Ryan J Ollos Owned by: Jun Omae
Priority: normal Component: TracPygit2Plugin
Severity: normal Keywords:
Cc: Trac Release:

Description

Error syncing a clone of the Trac repository:

$ git --version
git version 2.17.0
$ python -c "import pygit2; print(pygit2.__version__)"
0.26.4
$ trac-admin "/Users/rjollos/Documents/Workspace/trac-dev/tracenvs/proj-1.2" repository list
Name                      Type          Alias  Directory
-------------------------------------------------------------------------------------------------------------------------
[...]
teo                       pygit2               /Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git

$ trac-admin "/Users/rjollos/Documents/Workspace/trac-dev/tracenvs/proj-1.2" repository resync "teo"
[...]
13:20:58 Trac[pygit2_fs] INFO: Trying to sync revision [044e4497b50ae868e38f4060ead26c08171d9d0d]
AttributeError: '_pygit2.Patch' object has no attribute 'status'
13:20:58 Trac[console] ERROR: Exception in trac-admin command: u'repository resync teo'
Traceback (most recent call last):
  File "/Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git/trac/admin/console.py", line 112, in onecmd
    rv = cmd.Cmd.onecmd(self, line) or 0
  File "/usr/local/Cellar/python@2/2.7.14_3/Frameworks/Python.framework/Versions/2.7/lib/python2.7/cmd.py", line 220, in onecmd
    return self.default(line)
  File "/Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git/trac/admin/console.py", line 291, in default
    return self.cmd_mgr.execute_command(*args)
  File "/Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git/trac/admin/api.py", line 127, in execute_command
    return f(*fargs)
  File "/Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git/trac/versioncontrol/admin.py", line 162, in _do_resync
    self._sync(reponame, rev, clean=True)
  File "/Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git/trac/versioncontrol/admin.py", line 149, in _sync
    repos.sync(self._sync_feedback, clean=clean)
  File "/Users/rjollos/Documents/Workspace/trac-dev/trac-hacks/tracpygit2plugin/trunk/tracext/pygit2/pygit2_fs.py", line 243, in sync
    @self.env.with_transaction()
  File "/Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git/trac/db/api.py", line 97, in transaction_wrapper
    fn(ldb)
  File "/Users/rjollos/Documents/Workspace/trac-dev/trac-hacks/tracpygit2plugin/trunk/tracext/pygit2/pygit2_fs.py", line 246, in do_insert
    self._insert_cset(db, rev, cset)
  File "/Users/rjollos/Documents/Workspace/trac-dev/trac-hacks/tracpygit2plugin/trunk/tracext/pygit2/pygit2_fs.py", line 335, in _insert_cset
    return self.insert_changeset(rev, cset)
  File "/Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git/trac/versioncontrol/cache.py", line 273, in insert_changeset
    self._insert_changeset(db, rev, cset)
  File "/Users/rjollos/Documents/Workspace/trac-dev/teo-rjollos.git/trac/versioncontrol/cache.py", line 290, in _insert_changeset
    for path, kind, action, bpath, brev in cset.get_changes():
  File "/Users/rjollos/Documents/Workspace/trac-dev/trac-hacks/tracpygit2plugin/trunk/tracext/pygit2/pygit2_fs.py", line 1386, in get_changes
    files = self.repos._get_changes(parent.tree, commit.tree)
  File "/Users/rjollos/Documents/Workspace/trac-dev/trac-hacks/tracpygit2plugin/trunk/tracext/pygit2/pygit2_fs.py", line 837, in _get_changes
    for patch in diff) <= _diff_find_rename_limit:
  File "/Users/rjollos/Documents/Workspace/trac-dev/trac-hacks/tracpygit2plugin/trunk/tracext/pygit2/pygit2_fs.py", line 837, in <genexpr>
    for patch in diff) <= _diff_find_rename_limit:
AttributeError: '_pygit2.Patch' object has no attribute 'status'

Attachments (0)

Change History (0)

Modify Ticket

Change Properties
Set your email in Preferences
Action
as new The owner will remain Jun Omae.

Add Comment


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

 
Note: See TracTickets for help on using tickets.