Re: [viewvc-users] Annotation error

John Beranek <[email protected]>
Newsgroups gmane.comp.version-control.cvs.viewcvs.user
Organization John@Home
Message-ID <[email protected]>
C. Michael Pilato wrote:
> John Beranek wrote:
>> I have ViewVC 1.1.0-beta1 installed on a Linux server using:
>>
>> Apache 2.2.3
>> Subversion 1.5.6
>> Python 2.4.3
>>
>> It's a fairly new installation, and I've only just noticed that whenever 
>> an annotation of a file in a local Subversion repository is requested 
>> the error:
>>
>> Error occurred while calculating annotation data.
>>
>> is shown, and no annotation is provided.
> 
> Have you configured the svn_config_dir parameter in viewvc.conf, pointing it
> to a directory that is accessible to the user as whom ViewVC is running (the
> Apache user)?

No, but it appears to be happily falling back to $HOME/.subversion for 
the Apache user, which is writeable.

>> How do I go about diagnosing the problem? There is no further 
>> information in the Apache error log that I can find...
> 
> If you're comfortable temporarily tweaking your ViewVC source code, there is
> a line in lib/viewvc.py (around line 2124) that looks like this:
> 
>     annotation = 'error'
> 
> Change that to say, instead:
> 
>     raise

Ah:

Traceback (most recent call last):
   File "/usr/local/viewvc-1.1.0-beta1/lib/viewvc.py", line 4008, in main
     request.run_viewvc()
   File "/usr/local/viewvc-1.1.0-beta1/lib/viewvc.py", line 400, in 
run_viewvc
     self.view_func(self)
   File "/usr/local/viewvc-1.1.0-beta1/lib/viewvc.py", line 1573, in 
view_annotate
     markup_or_annotate(request, 1)
   File "/usr/local/viewvc-1.1.0-beta1/lib/viewvc.py", line 1482, in 
markup_or_annotate
     blame_source, revision = request.repos.annotate(path, rev)
   File "/usr/local/viewvc-1.1.0-beta1/lib/vclib/svn/svn_repos.py", line 
554, in annotate
     youngest_rev, oldest_rev)
   File "/usr/local/viewvc-1.1.0-beta1/lib/vclib/svn/svn_repos.py", line 
309, in __init__
     ctx.config = core.svn_config_get_config(None)
   File "/usr/lib64/python2.4/site-packages/libsvn/core.py", line 3505, 
in svn_config_get_config
     return apply(_core.svn_config_get_config, args)
SubversionException: ("Can't open file '/root/.subversion/servers': 
Permission denied", 13)

Why would it think $HOME is /root - presumably because when Apache 
changes UID it doesn't set HOME?

Many thanks for your (quick!) help.

John.

-- 
John Beranek                         To generalise is to be an idiot.
http://redux.org.uk/                                 -- William Blake

------------------------------------------------------
http://viewvc.tigris.org/ds/viewMessage.do?dsForumId=4255&dsMessageId=1892380

To unsubscribe from this discussion, e-mail: [[email protected]].
smime.p7s (application/x-pkcs7-signature, 3.3 KB) - not displayed
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.