Skip to content

Commit

Permalink
Merge remote-tracking branch 'richtja/doc_backport' into 92lts
Browse files Browse the repository at this point in the history
Signed-off-by: Cleber Rosa <crosa@redhat.com>
  • Loading branch information
clebergnu committed Apr 11, 2024
2 parents 1159721 + b8bdb28 commit 67fa9c0
Show file tree
Hide file tree
Showing 8 changed files with 48 additions and 19 deletions.
24 changes: 24 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.11"

# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docs/source/conf.py

# We recommend specifying your dependencies to enable reproducible builds:
# https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
python:
install:
- requirements: requirements-doc.txt
- method: pip
path: .
4 changes: 2 additions & 2 deletions avocado/core/runners/utils/messages.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ def get(cls, result, fail_reason=None, returncode=None): # pylint: disable=W022
"""Creates finished message with all necessary information.
:param result: test result
:type result values for the statuses defined in
:class: avocado.core.teststatus.STATUSES
:type result: values for the statuses defined in
:class: avocado.core.teststatus.STATUSES
:param fail_reason: parameter for brief specification, of the failed
result.
:type fail_reason: str
Expand Down
3 changes: 2 additions & 1 deletion avocado/utils/external/gdbmi_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,8 @@ def t_whitespace(self, s): # pylint: disable=W0613
r'[ \t\f\v]+'

def t_symbol(self, s):
r',|\{|\}|\[|\]|\='
"""""" # pylint: disable=C0112
r",|\{|\}|\[|\]|\=" # pylint: disable=w0105
self.rv.append(Token(s, s))

def t_result_type(self, s):
Expand Down
2 changes: 1 addition & 1 deletion docs/source/blueprints/BP003.rst
Original file line number Diff line number Diff line change
Expand Up @@ -544,7 +544,7 @@ scheduler". They are provided for discussion only and do not
constitute hard requirements for this or future work.

Tasks' requirements fulfillment
------------------------------
-------------------------------

1. Prepare for the execution of a task, such as the fulfillment of extra task
requirements. The requirements resolver is one, if not the only way,
Expand Down
4 changes: 3 additions & 1 deletion docs/source/blueprints/template.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
:orphan:

BP???
#####

.. Please refer to BP000 for detailed instructions on how to write a
BluePrint (and remove this comment from your final document).
BluePrint (and remove this comment and :orphan: tag from your final document).
:Number: BP???
:Title:
Expand Down
22 changes: 8 additions & 14 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,6 @@
sys.path.insert(0, ROOT_PATH)


# Flag that tells if the docs are being built on readthedocs.org
ON_RTD = os.environ.get('READTHEDOCS', None) == 'True'

#
# Auto generate API documentation
#
Expand Down Expand Up @@ -189,10 +186,13 @@ def generate_vmimage_distro():
os.unlink(os.path.join(output_dir, "modules.rst"))
optional_plugins_toc.write("\n %s" % os.path.join(name, name))

extensions = ['sphinx.ext.autodoc', # pylint: disable=C0103
'sphinx.ext.intersphinx',
'sphinx.ext.todo',
'sphinx.ext.coverage']
extensions = [
"sphinx.ext.autodoc", # pylint: disable=C0103
"sphinx.ext.intersphinx",
"sphinx.ext.todo",
"sphinx.ext.coverage",
"sphinx_rtd_theme",
]

master_doc = 'index' # pylint: disable=C0103
project = u'Avocado' # pylint: disable=C0103
Expand All @@ -203,13 +203,7 @@ def generate_vmimage_distro():
version = VERSION # pylint: disable=C0103
release = VERSION # pylint: disable=C0103

if not ON_RTD: # only import and set the theme if we're building docs locally
try:
import sphinx_rtd_theme
html_theme = 'sphinx_rtd_theme' # pylint: disable=C0103
html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] # pylint: disable=C0103
except ImportError:
html_theme = 'default' # pylint: disable=C0103
html_theme = "sphinx_rtd_theme" # pylint: disable=C0103

htmlhelp_basename = 'avocadodoc' # pylint: disable=C0103

Expand Down
7 changes: 7 additions & 0 deletions docs/source/guides/contributor/chapters/runners.rst
Original file line number Diff line number Diff line change
Expand Up @@ -599,20 +599,27 @@ Supported message types
~~~~~~~~~~~~~~~~~~~~~~~

.. autoclass:: avocado.core.messages.StartMessageHandler
:noindex:

.. autoclass:: avocado.core.messages.FinishMessageHandler
:noindex:

Running messages
++++++++++++++++
This message can be used during the run-time and has different properties
based on the information which is being transmitted.

.. autoclass:: avocado.core.messages.LogMessageHandler
:noindex:

.. autoclass:: avocado.core.messages.StdoutMessageHandler
:noindex:

.. autoclass:: avocado.core.messages.StderrMessageHandler
:noindex:

.. autoclass:: avocado.core.messages.WhiteboardMessageHandler
:noindex:

.. autoclass:: avocado.core.messages.FileMessageHandler
:noindex:
1 change: 1 addition & 0 deletions requirements-doc.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
sphinx-rtd-theme==2.0.0

0 comments on commit 67fa9c0

Please sign in to comment.