On Tue, Feb 04, 2014 at 02:02:42PM -0700, Tim Flink wrote: > ---- SNIP ---- > > What I'm looking to decide is whether we really need args in addition to > of key=value pairs and if the added complexity is worth it. > > I propose that we alter the format to use only key=value pairs which > would be parsed into a dict in the runner. Using the same example as > above, the new action would look something like: > > ------------------------------------------------------------ > Execution: > python: pyfile=runtask.py method_name=do_something action=fix > ------------------------------------------------------------ > > This would simplify the parsing code and the data passing logic for > execution since all input data would be in the form of a dictionary > instead of separated out into a list/string and a dictionary. > > While I slightly prefer the aesthetics of allowing one or more > keyless args in an action instead of all key=value pairs, I can't think > of a use case where restricting input to key=value pairs would cause > problems. > > If we do decide that keyless args are needed, I'd rather support more > than one instead of the current arbitrary restriction of just one arg. > > Any other thoughts? > > Tim
How about something like this: ------------------------------------------------------------ Execution: python: file: runtask.py method: do_something args: - first_positional_arg - second_positional_arg kwargs: action: fix ------------------------------------------------------------ It takes many more lines to express a task, but the indentation shows structure and it is much more flexible. Perhaps it is overkill?
pgpomBnFqa3mH.pgp
Description: PGP signature
_______________________________________________ qa-devel mailing list qa-devel@lists.fedoraproject.org https://admin.fedoraproject.org/mailman/listinfo/qa-devel