Re: [Freeipa-devel] [PATCH] Fix File parameter validation when prompting.

2010-01-29 Thread Pavel Zuna
John Dennis wrote: I've been thinking about this a bit more. I wonder if part of the inelegance is due to the fact we're trying to shoehorn two distinct concepts into one item when a proper relationship does not exist. It does not seem logical that a file is a subclass of a string which is

Re: [Freeipa-devel] [PATCH] Fix File parameter validation when prompting.

2010-01-29 Thread John Dennis
On 01/29/2010 07:53 AM, Pavel Zuna wrote: John Dennis wrote: In this scheme the you don't need to keep state, you don't need to special case any code, you can use the existing normalize and validate mechanisms. The problem here is that validate/normalize can only be used on final values passed

Re: [Freeipa-devel] [PATCH] Fix File parameter validation when prompting.

2010-01-29 Thread Pavel Zuna
John Dennis wrote: On 01/29/2010 07:53 AM, Pavel Zuna wrote: John Dennis wrote: In this scheme the you don't need to keep state, you don't need to special case any code, you can use the existing normalize and validate mechanisms. The problem here is that validate/normalize can only be used on

Re: [Freeipa-devel] [PATCH] Fix File parameter validation when prompting.

2010-01-28 Thread Jason Gerard DeRose
On Wed, 2010-01-27 at 17:53 +0100, Pavel Zuna wrote: cli.prompt_interactively now loads files before validating the parameter value. It also populates a list of already loaded files, so that cli.load_files knows when a parameter already contains the file contents. Fix #557163 Pavel

Re: [Freeipa-devel] [PATCH] Fix File parameter validation when prompting.

2010-01-28 Thread John Dennis
I've been thinking about this a bit more. I wonder if part of the inelegance is due to the fact we're trying to shoehorn two distinct concepts into one item when a proper relationship does not exist. It does not seem logical that a file is a subclass of a string which is how this is set up