Add a docs build job to CI (#1328)

* Add a docs build job to CI

* Add sphinxopts to fail on warning

* Test sphinx warning

* Redid ci stage conditionals

* update conf.py to remove deprecation warning

* introduce 3rd stage for proper conditionals

* Attempt to fix malformed table

Co-authored-by: Ogi Moore <ognyan.moore@gmail.com>
This commit is contained in:
Kenneth Lyons 2020-10-15 08:43:23 -07:00 committed by GitHub
parent 3b6eb02520
commit 1f76ac0e2c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 25 additions and 10 deletions

View File

@ -20,7 +20,7 @@ variables:
disable.coverage.autogenerate: 'true'
stages:
- stage: "pre_test"
- stage: pre_build
jobs:
- job: check_diff_size
pool:
@ -53,8 +53,6 @@ stages:
echo -e "Estimated content size difference = ${SIZE_DIFF} kB" &&
test ${SIZE_DIFF} -lt 100;
displayName: 'Diff Size Check'
continueOnError: true
- job: "style_check"
pool:
vmImage: "Ubuntu 18.04"
@ -66,8 +64,22 @@ stages:
pip install flake8
python setup.py style
displayName: 'flake8 check'
continueOnError: true
- job: "build_docs"
pool:
vmImage: 'Ubuntu 18.04'
steps:
- task: UsePythonVersion@0
inputs:
versionSpec: 3.8
- script: |
cd doc
python -m pip install -r requirements.txt
make html SPHINXOPTS='-W -v'
displayName: "Build docs"
- stage: build
dependsOn: []
jobs:
- job: "build_wheel"
pool:
vmImage: 'Ubuntu 18.04'
@ -83,7 +95,9 @@ stages:
- publish: dist
artifact: wheel
- stage: "test"
- stage: test
displayName: "Test Suite"
dependsOn: build
jobs:
- template: azure-test-template.yml
parameters:
@ -96,4 +110,4 @@ stages:
- template: azure-test-template.yml
parameters:
name: macOS
vmImage: 'macOS-10.15'
vmImage: 'macOS-10.15'

View File

@ -139,7 +139,7 @@ html_static_path = ['_static']
# add the theme customizations
def setup(app):
app.add_stylesheet("custom.css")
app.add_css_file("custom.css")
# If not '', a 'Last updated on:' timestamp is inserted at every page bottom,
# using the given strftime format.

View File

@ -14,14 +14,15 @@ __all__ = ['AxisItem']
class AxisItem(GraphicsWidget):
"""
GraphicsItem showing a single plot axis with ticks, values, and label.
Can be configured to fit on any side of a plot, and can automatically synchronize its displayed scale with ViewBox items.
Can be configured to fit on any side of a plot,
Can automatically synchronize its displayed scale with ViewBox items.
Ticks can be extended to draw a grid.
If maxTickLength is negative, ticks point into the plot.
"""
def __init__(self, orientation, pen=None, textPen=None, linkView=None, parent=None, maxTickLength=-5, showValues=True, text='', units='', unitPrefix='', **args):
"""
============== ===============================================================
=============== ===============================================================
**Arguments:**
orientation one of 'left', 'right', 'top', or 'bottom'
maxTickLength (px) maximum length of ticks to draw. Negative values draw
@ -39,7 +40,7 @@ class AxisItem(GraphicsWidget):
range of data displayed.
args All extra keyword arguments become CSS style options for
the <span> tag which will surround the axis label and units.
============== ===============================================================
=============== ===============================================================
"""
GraphicsWidget.__init__(self, parent)