diff options
author | Paul Eggleton <paul.eggleton@linux.intel.com> | 2015-12-22 17:03:08 +1300 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-12-22 16:44:03 +0000 |
commit | 98fd5de373e16fe5d69a3065f844efc8037385bc (patch) | |
tree | 6f893fa92729821a83126e76e1546ed070bed7ad /meta/classes/prexport.bbclass | |
parent | c0754d672966901f22dff1bcd40bbd08d1219c7a (diff) | |
download | openembedded-core-98fd5de373e16fe5d69a3065f844efc8037385bc.tar.gz openembedded-core-98fd5de373e16fe5d69a3065f844efc8037385bc.tar.bz2 openembedded-core-98fd5de373e16fe5d69a3065f844efc8037385bc.zip |
scripts/lib/argparse_oe: handle intermixing of optional positional arguments
Python's argparse module can't handle when several optional positional
arguments (set with nargs='?') are intermixed with other options. If the
positional arguments aren't optional then this isn't an issue; thus when
changing positional arguments to optional (as we are doing with devtool)
we need this workaround.
This is a pretty horrible hack, but we don't want this flexibility of
ordering to disappear simply because we made some arguments optional.
Unfortunately the corresponding bug remains unresolved upstream even in
Python 3, and argparse is not really designed to be subclassed so it
doesn't make things like this easy.
Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/classes/prexport.bbclass')
0 files changed, 0 insertions, 0 deletions