gnu-arch-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnu-arch-users] PyArch patches


From: David Allouche
Subject: Re: [Gnu-arch-users] PyArch patches
Date: Fri, 25 Jun 2004 15:16:47 +0200
User-agent: Mutt/1.5.6+20040523i

On Sun, Jun 20, 2004 at 06:42:48PM -0400, Aaron Bentley wrote:
> David Allouche wrote:
> 
> >Since tla is about to be
> >localized, parsing the error logs is no longer really an option, so tla
> >should maybe be modified to have particular exit status for those cases.
> 
> I wouldn't be surprised if it was trivial to force tla into default 
> English mode.  Probably it would just require changing a locale 
> variable.  But in that case, a pyArch program that was localized would 
> have to interpret every possible error.

I think that would be a bad thing. We want the locale preserved because
the error messages are useful information to give to the user.  For
example, when something goes wrong with tla in octopy, it displays the
command that caused the error and its output in a pop-up window.

Natural language messages from tla are part of the user interface.
Pyarch is not allowed to mess with that.


> >>What I have to do is iterate through the logs in order to find out 
> >>whether the specified log exists, and return it if so.  That's exactly 
> >>what get_log did.
> >
> >
> >How hackish... on the other hand tla does not really provide existence
> >predicates for anything.
> 
> It's not just tla.  libarch doesn't provide existence predicates for 
> anything, either.  (Except revisions, and I added that.)

*shrugs* anyway it's just one more cross for pyarch to bear before tla
is librified.


> >Testing for the existence of namespace objects
> >is currently done, very unefficiently, more or less along those lines in
> >the arch.py "exists" methods and _tla.py "*_exists" functions.
> 
> Which is more or less how they're done in tla also.  (I just rewrote the
> input validation stuff.  Sorry.)

Except having to implement that logic at the pyarch level currently
involves spawning several tla processes and may involve negociating
several ssh connections.


> >I think the correct way would be:
> [detailed description of the correct way]
> 
> You can kinda see why I skipped all that, eh?  I've done it in my 
> cat-log function, so I don't have an immediate need anymore.  Still, I 
> can imagine putting it in sometime when I'm bored.

I can see.

Completely unrelated: I'm starting to be concerned about all these
constructive design discussions we are having being lost in the mailing
list archives... Maybe we should put them on the wiki or somewhere
within pyarch source tree?

-- 
                                                            -- ddaa




reply via email to

[Prev in Thread] Current Thread [Next in Thread]