Skip to content

fix: Fix documentation build with extra dependencies #566

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 31, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 19 additions & 5 deletions .readthedocs.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,21 @@
version: 2

formats: all

build:
image: latest
os: ubuntu-22.04
tools:
python: "3.7"

sphinx:
configuration: docs/conf.py

python:
version: 3.7
pip_install: true
extra_requirements:
- docs
install:
- requirements: docs/requirements.txt
- method: pip
path: .
extra_requirements:
- async
- extra
- ciso
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ This release introduces a support for new version of InfluxDB API definitions wi
1. [#583](https://github.com/influxdata/influxdb-client-python/pull/583): Async HTTP client doesn't always use `HTTP_PROXY`/`HTTPS_PROXY` environment variables. [async/await]
1. [#584](https://github.com/influxdata/influxdb-client-python/pull/584): Parsing empty query result value as `numpy.NaN`

### Documentation
1. [#566](https://github.com/influxdata/influxdb-client-python/pull/566): Fix Sphinx documentation build and add support `.readthedocs.yml` V2 configuration file

## 1.36.1 [2023-02-23]

### Bug Fixes
Expand Down
10 changes: 5 additions & 5 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ If your application uses async/await in Python you can install with the ``async`

$ pip install influxdb-client[async]

For more info se `How to use Asyncio`_.
For more info see `How to use Asyncio`.

Setuptools
^^^^^^^^^^
Expand Down Expand Up @@ -208,7 +208,7 @@ The following options are supported:

self.client = InfluxDBClient.from_config_file("config.ini")

.. code-block::
.. code-block:: ini

[influx2]
url=http://localhost:8086
Expand Down Expand Up @@ -278,7 +278,7 @@ Example how to enable profilers using API:

Example of a profiler output:

.. code-block::
.. code-block:: text

===============
Profiler: query
Expand Down Expand Up @@ -374,7 +374,7 @@ Example how to use profilers with callback:

Example output of this callback:

.. code-block::
.. code-block:: text

Custom processing of profiler result: {'result': '_profiler', 'table': 0, '_measurement': 'profiler/query', 'TotalDuration': 18843792, 'CompileDuration': 1078666, 'QueueDuration': 93375, 'PlanDuration': 0, 'RequeueDuration': 0, 'ExecuteDuration': 17371000, 'Concurrency': 0, 'MaxAllocated': 448, 'TotalAllocated': 0, 'RuntimeErrors': None, 'flux/query-plan': 'digraph {\r\n ReadRange2\r\n generated_yield\r\n\r\n ReadRange2 -> generated_yield\r\n}\r\n\r\n', 'influxdb/scanned-bytes': 0, 'influxdb/scanned-values': 0}
Custom processing of profiler result: {'result': '_profiler', 'table': 1, '_measurement': 'profiler/operator', 'Type': '*influxdb.readFilterSource', 'Label': 'ReadRange2', 'Count': 1, 'MinDuration': 3274084, 'MaxDuration': 3274084, 'DurationSum': 3274084, 'MeanDuration': 3274084.0}
Expand Down Expand Up @@ -773,7 +773,7 @@ The ``client`` is able to retrieve data in `Pandas DataFrame <https://pandas.pyd

Output:

.. code-block::
.. code-block:: text

result table location temperature
0 _result 0 New York 24.3
Expand Down
13 changes: 7 additions & 6 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,6 @@
exec('\n'.join(l for l in f if l.startswith('VERSION')), meta)


def setup(app):
app.add_stylesheet('custom.css')


project = 'influxdb_client'
copyright = '2022 InfluxData, Inc'
author = 'Robert Hajek, Jakub Bednar'
Expand Down Expand Up @@ -57,7 +53,8 @@ def setup(app):
'sphinx.ext.coverage',
'sphinx.ext.mathjax',
'sphinx.ext.todo',
'sphinx.ext.viewcode'
'sphinx.ext.viewcode',
'sphinx_rtd_theme',
# 'sphinx_autodoc_typehints'
]

Expand All @@ -78,7 +75,7 @@ def setup(app):
#
# This is also used if you do content translation via gettext catalogs.
# Usually you set "language" from the command line for these cases.
language = None
language = "en"

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
Expand All @@ -101,6 +98,10 @@ def setup(app):
#
# html_theme_options = {}

html_css_files = [
'custom.css',
]

# Add any paths that contain custom static files (such as style sheets) here,
# relative to this directory. They are copied after the builtin static files,
# so a file named "default.css" will overwrite the builtin "default.css".
Expand Down
3 changes: 2 additions & 1 deletion docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
docutils < 0.18
sphinx>=5.0.0
sphinx_rtd_theme==1.1.0