Opened 5 years ago

Closed 5 years ago

Last modified 4 years ago

#5480 closed defect (invalid)

GitError: GIT control files not found

Reported by: tmontuori@… Owned by: hvr
Priority: normal Component: GitPlugin
Severity: normal Keywords:
Cc: Trac Release: 0.11


Attempted to use GitPlugin (v.; most recent SVN version as of today) to provide git repository support for a project. GitPlugin installs just fine using python-setuptools. Too, when using tracd to host, the plugin works fine. However, when using mod_python, I get this error:

Trac detected an internal error:

GitError: GIT control files not found, maybe wrong directory?

I think that the problem is in this mess:

2009-07-06 17:14:15,200 Trac[git_fs] INFO: detected GIT version
2009-07-06 17:14:15,200 Trac[PyGIT] ERROR: GIT control files missing in '/home/tony/bin/eggdrop/scripts/.git'
2009-07-06 17:14:15,202 Trac[main] ERROR: Internal Server Error: 
Traceback (most recent call last):
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/web/", line 435, in _dispatch_request
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/web/", line 175, in dispatch
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/web/", line 298, in _pre_process_request
    chosen_handler = filter_.pre_process_request(req, chosen_handler)
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/versioncontrol/", line 86, in pre_process_request
  File "/usr/lib/python2.5/site-packages/Trac-0.11.4-py2.5.egg/trac/versioncontrol/", line 157, in get_repository
    repos = self._connector.get_repository(rtype, rdir, authname)
  File "build/bdist.linux-i686/egg/tracext/git/", line 159, in get_repository
  File "build/bdist.linux-i686/egg/tracext/git/", line 176, in __init__ 
  File "build/bdist.linux-i686/egg/tracext/git/", line 120, in __init__
    i = Storage(repo, log, git_bin)
  File "build/bdist.linux-i686/egg/tracext/git/", line 194, in __init__
    raise GitError("GIT control files not found, maybe wrong directory?")
GitError: GIT control files not found, maybe wrong directory?

...but just in case I'm wrong, I've attached my trac.log and trac.ini files.

Attachments (1)

trac.log (47.7 KB) - added by tmontuori@… 5 years ago.
Trac log file

Download all attachments as: .zip

Change History (3)

Changed 5 years ago by tmontuori@…

Trac log file

comment:1 Changed 5 years ago by tmontuori@…

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

Figured out what the issue is; the git repo wasn't owned by the user that Apache/mod_python runs as.

Bit of a nuisance, but makes sense anyway.

comment:2 Changed 4 years ago by anonymous

/!\ NOTE: the Test.git above needs to be the .git repository directory (i.e. the one containing the file HEAD and config), not the working tree directory that holds the .git/ folder.

Add Comment

Modify Ticket

as closed .
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from hvr. Next status will be 'closed'.
The resolution will be deleted. Next status will be 'reopened'.

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

Note: See TracTickets for help on using tickets.