Warn when deprecated options are passed to commands and improve their docs.
Review Request #14623 — Created Sept. 25, 2025 and updated
We currently allow for
rbt
options to be marked as deprecated, and we'll
display deprecation info in the documentation and help text for the option.
But we weren’t emitting any warnings when users actually passed them on
the command line. This change allowsrbt
to emit a deprecation warning
when a deprecated option is used.This change also allows setting a replacement option and the version in
which the option will be removed. Our sphinx documentation building
functions and help text building logic have been updated to include these.I decided to move our RBTools-specific option attributes out of
Option.attrs
and made them direct attributes on theOption
class
instead. This keeps a clearer separation from theargparse
arguments
and lets us keep this information around after the Option is added to
the parser (previously we would strip all of our custom attributes
before adding an option to the parser). We also get easy typing on
these attributes now.We also recently marked
rbt login'
s--enable-logging
as deprecated, and
this change defines its replacement (--debug
) and removal version (6.0).
- Tested
rbt login -l
saw the deprecation warning - Tested
rbt login
with options other than-l
, saw no warnings - Ran unit tests.
- Built docs and looked at options that have one or more of the custom
RBTools attributes (config key, extended help, added in and the various
deprecation related attributes).

- Commits:
-
Summary ID f5af1a0f4b96e06beaec8cc8aface92aa9acb8b1 d8611fe93455105d6333a6fa533d85872ba6af5f