You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For production code, however, using Typer's echo or secho may be the better choice, especially since Typer offers fine grained control over the formatting of the output string, including color.
The text was updated successfully, but these errors were encountered:
As recommended in [Logging HOWTO ](https://docs.python.org/3.8/howto/logging.html#basic-logging-tutorial) if you want to "Display console output for ordinary usage of a command line script or program" the "best tool for the task" is
print()
, or in this case, the Typer equivalents,echo
orsecho
.During development, using
logging
as a unified messaging and notification channel is extremely useful, especially considering pytest's support forlogging
-- see [Logging — pytest documentation](https://docs.pytest.org/en/6.2.x/logging.html).For production code, however, using Typer's
echo
orsecho
may be the better choice, especially since Typer offers fine grained control over the formatting of the output string, including color.The text was updated successfully, but these errors were encountered: