You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by sebb <se...@gmail.com> on 2018/05/25 13:14:56 UTC

Bug in tools/server-side/svnpubsub/svnwcsub.py

The following fails because fname is not defined:

self.read(fname) [1]

it should be

self.read(self.fname)

[1] http://svn.apache.org/viewvc/subversion/trunk/tools/server-side/svnpubsub/svnwcsub.py?view=markup#l378

Re: Bug in tools/server-side/svnpubsub/svnwcsub.py

Posted by sebb <se...@gmail.com>.
On 25 May 2018 at 15:51, Daniel Shahaf <d....@daniel.shahaf.name> wrote:
> [moved from users@]
>
> sebb wrote on Fri, 25 May 2018 15:15 +0100:
>> On 25 May 2018 at 14:37, Daniel Shahaf <d....@daniel.shahaf.name> wrote:
>> > sebb wrote on Fri, 25 May 2018 14:14 +0100:
>> >> The following fails because fname is not defined:
>> >>
>> >> self.read(fname) [1]
>> >>
>> >> it should be
>> >>
>> >> self.read(self.fname)
>> >
>> > Thanks for the report.
>> > With that change, the [DEFAULT] section doesn't get emptied by reload().
>>
>> Seems to me that is a separate issue.
>>
>
> Right now, reload() raises NameError whenever called.
>
> Fixing the NameError without making reload() reload the [DEFAULT]
> section would make reload() silently broken.
>
> Therefore, I think the [DEFAULT] non-emptying should be fixed at the
> same time as fixing the NameError.

OK, understood.

>> > Would you like to send a patch that fixes that as well (in addition to the NameError)?
>>
>> I've no idea how to patch that.
>> I just know that my proposed fix stops the reload from failing.
>>
>> > Replies to dev@, please.
>>
>> Do you want me to raise a JIRA for the NameError?
>
> Only if the invisible hand doesn't produce a patch that fixes both issues... :-)

I'm not following the Subversion lists, so I won't know.

It's not an issue that affects me directly.
I just stumbled across it and decided to report it.
I've already spent more time on in than I expected.

Sorry, but I'll have to leave the rest for others to complete.

> Daniel
>
> P.S. If there hadn't been the [DEFAULT] issue I'd have just asked you to
>      commit your patch, but as explained above, that issue's existence
>      means the patch would trade a loud failure mode for a silent one.

Re: Bug in tools/server-side/svnpubsub/svnwcsub.py

Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
[moved from users@]

sebb wrote on Fri, 25 May 2018 15:15 +0100:
> On 25 May 2018 at 14:37, Daniel Shahaf <d....@daniel.shahaf.name> wrote:
> > sebb wrote on Fri, 25 May 2018 14:14 +0100:
> >> The following fails because fname is not defined:
> >>
> >> self.read(fname) [1]
> >>
> >> it should be
> >>
> >> self.read(self.fname)
> >
> > Thanks for the report.
> > With that change, the [DEFAULT] section doesn't get emptied by reload().
> 
> Seems to me that is a separate issue.
> 

Right now, reload() raises NameError whenever called.

Fixing the NameError without making reload() reload the [DEFAULT]
section would make reload() silently broken.

Therefore, I think the [DEFAULT] non-emptying should be fixed at the
same time as fixing the NameError.

> > Would you like to send a patch that fixes that as well (in addition to the NameError)?
> 
> I've no idea how to patch that.
> I just know that my proposed fix stops the reload from failing.
> 
> > Replies to dev@, please.
> 
> Do you want me to raise a JIRA for the NameError?

Only if the invisible hand doesn't produce a patch that fixes both issues... :-)

Daniel

P.S. If there hadn't been the [DEFAULT] issue I'd have just asked you to
     commit your patch, but as explained above, that issue's existence
     means the patch would trade a loud failure mode for a silent one.

Re: Bug in tools/server-side/svnpubsub/svnwcsub.py

Posted by sebb <se...@gmail.com>.
On 25 May 2018 at 14:37, Daniel Shahaf <d....@daniel.shahaf.name> wrote:
> sebb wrote on Fri, 25 May 2018 14:14 +0100:
>> The following fails because fname is not defined:
>>
>> self.read(fname) [1]
>>
>> it should be
>>
>> self.read(self.fname)
>
> Thanks for the report.

OK.

> With that change, the [DEFAULT] section doesn't get emptied by reload().

Seems to me that is a separate issue.

> Would you like to send a patch that fixes that as well (in addition to the NameError)?

I've no idea how to patch that.
I just know that my proposed fix stops the reload from failing.

> Replies to dev@, please.

Do you want me to raise a JIRA for the NameError?

> Cheers,
>
> Daniel

Re: Bug in tools/server-side/svnpubsub/svnwcsub.py

Posted by Daniel Shahaf <d....@daniel.shahaf.name>.
sebb wrote on Fri, 25 May 2018 14:14 +0100:
> The following fails because fname is not defined:
> 
> self.read(fname) [1]
> 
> it should be
> 
> self.read(self.fname)

Thanks for the report.  With that change, the [DEFAULT] section doesn't
get emptied by reload().  Would you like to send a patch that fixes that
as well (in addition to the NameError)?

Replies to dev@, please.

Cheers,

Daniel