[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: GNU Parallel Bug Reports --header and --colsep parsing is aberrant w
From: |
Ole Tange |
Subject: |
Re: GNU Parallel Bug Reports --header and --colsep parsing is aberrant when used without arguments |
Date: |
Sat, 1 Jul 2017 05:43:03 +0200 |
On Sat, Jul 1, 2017 at 1:26 AM, Coby Viner <address@hidden> wrote:
> --header and --colsep parsing is aberrant when used without arguments.
First: Thanks for an error report that is very easy to understand. I
wish all error reports where as well written as this.
> Error example:
>
> Failing case 1:
>
> address@hidden:~] parallel --dry-run -j 1 --header --colsep '\t' "echo
> f1={f-1} f2={f2}" :::: <(perl -e 'printf "f-1\tf2\nA\tB\nC\tD\n"')
> \t echo f1=A f2=B
> \t echo f1=C f2=D
Here you are giving --header the argument of '--colsep'. So the equivalent is:
parallel --header '--colsep' --dry-run -j 1 '\t' "echo f1={f-1}
f2={f2}" :::: <(perl -e 'printf "f-1\tf2\nA\tB\nC\tD\n"')
--header always takes an argument and you are giving it one (albeit a
weird one).
> Failing case 2:
>
> address@hidden:~] parallel --dry-run -j 1 --header '.*\n' --colsep "echo
> f1={f-1} f2={f2}" :::: <(perl -e 'printf "f-1\tf2\nA\tB\nC\tD\n"')
Here you give --colsep the argument "echo f1={f-1} f2={f2}". This is
also a pretty weird argument to give --colsep.
In both cases I do not see a way to detect this: You _should_ be able
to give pretty weird input to both --colsep and --header if your data
requires this.
> Description:
>
> It appears that --header and --colsep when used with their default arguments
> can produce inconsistent results, if an argument is provided to only one of
> the two parameters. The result is counter-intuitive.
There is no default argument - they _always_ take an argument.
/Ole