[cvsnt] Re: ANN: ViewCvs installer updated with rcsparse fix
Bo Berglund
bo.berglund at telia.com
Sat Mar 27 15:04:34 GMT 2004
On Tue, 23 Mar 2004 17:11:35 -0700, Glen Starrett <grstarrett at cox.net>
wrote:
>Glen Starrett wrote:
>> I don't know if this is a problem with the latest or just my
>> installation (the server is seriously hosed in some respects) but I'm
>> getting an error "NameError: global name 'where' is not defined" (full
>> text below).
>
>I've found out it's a small problem in one of the files. In
>c:\programs\ViewCvs\lib\vclib\bincvs\__init__.py, at line 131 you'll see:
>
> if filename != full_name:
> raise vclib.Error(
> 'The filename from co did not match. Found "%s". Wanted "%s"<br>'
> 'url="%s"' % (filename, full_name, where))
>
>At that point "where" is undefined, thus the error. However, there's
>another kink in there that \ and / are not equal yet are mixed at that
>point in one of the strings. I was able to hack this to fix it --
>treating both strings probably isn't necessary, and there may be a more
>appropriate place to do it, but this works:
>
> if string.replace(filename,'\\','/') !=
>string.replace(full_name,'\\','/'):
> raise vclib.Error(
> 'The filename from co did not match. Found "%s". Wanted "%s"<br>'
> % (filename, full_name))
>
>
>Please advise if this would be better done some other way. I'm
>unfamiliar with both python and ViewCVS internals.
>
>Regards,
Since no developer on the ViewCvs list responded to my request for
them to have a look at this and check in a working py file I am
inclined to anyway include your patch in my ViewCvs installer.
But then I need to know what the replacement you did here actually
means:
Old line:
'url="%s"' % (filename, full_name, where))
New line:
% (filename, full_name))
What happened to 'url="%s"' ?? Can you just remove it without ill
effects? I see that where is also removed, what consequences does this
have?
Since I don't really understand what is happening right there I would
be glad if you could expand on that (provided you know of course...)
/Bo
(Bo Berglund, developer in Sweden)
More information about the cvsnt
mailing list