1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00
community.general/docs/docsite/rst/dev_guide/testing/sanity/no-main-display.rst

13 lines
390 B
ReStructuredText
Raw Normal View History

Sanity Tests » no-main-display
==============================
As of Ansible 2.8, ``Display`` should no longer be imported from ``__main__``.
``Display`` is now a singleton and should be utilized like the following::
from ansible.utils.display import Display
display = Display()
There is no longer a need to attempt ``from __main__ import display`` inside
a ``try/except`` block.