Skip to content

Add a docs build job to CI#1328

Merged
j9ac9k merged 7 commits intopyqtgraph:masterfrom
ixjlyons:docs-ci
Oct 15, 2020
Merged

Add a docs build job to CI#1328
j9ac9k merged 7 commits intopyqtgraph:masterfrom
ixjlyons:docs-ci

Conversation

@ixjlyons
Copy link
Copy Markdown
Member

Just an idea - it might be nice to catch docs issues in PRs before merging and finding out via readthedocs.

Seems like it'd be easy to publish the built docs as an artifact, but I don't know if there's a reasonable way to look at them without downloading a zip and opening manually.

Also, feedback welcome on where this should go in the pipeline - I'm not sure pre-test is the right stage.

@ixjlyons ixjlyons marked this pull request as draft July 27, 2020 21:32
@ixjlyons
Copy link
Copy Markdown
Member Author

Converting this to draft for now. I'd like to test that creating a warning/error in the docs build makes the check fail in an obvious way - it's not clear to me at the moment that's the case.

@ixjlyons
Copy link
Copy Markdown
Member Author

Not exactly what I expected: https://dev.azure.com/pyqtgraph/pyqtgraph/_build/results?buildId=1079&view=results

I guess because continueOnError: true is set, failures are reported (to github) as successes. I was thinking ideally we would see in the github interface that the docs build failed but still run the tests. This seems to imply the same problem exists for the other pre_test jobs (except build_wheel).

I think there are a few options:

  • Just remove continueOnError. I'm still thinking this is not ideal since getting a PR to pass code tests is usually higher priority than docs.
  • Add condition: succeededOrFailed() to the test stage and remove continueOnError for the build_docs job. This is also probably not what we want because failing the wheel build should prevent running tests it seems.
  • Add the docs_build job to the test stage or to a new post_test stage. I'm leaning toward this option, though I don't know what to do about reporting issues with the other pre_test jobs.

@j9ac9k
Copy link
Copy Markdown
Member

j9ac9k commented Sep 30, 2020

Hey, I think this PR should definitely be merged as I don't want to find out our docs are broken just by browsing RTD...

While running the docs, I did get this warning

/Users/ogi/Developer/pyqtgraph/doc/source/conf.py:142: RemovedInSphinx40Warning: The app.add_stylesheet() is deprecated. Please use app.add_css_file() instead.

@ixjlyons
Copy link
Copy Markdown
Member Author

ixjlyons commented Oct 1, 2020

Yeah, haven't revisited this in a while. I noticed the same warning and I believe it's been fixed in sphinx_rtd_theme 0.5.0. Things like that are why I'm a little hesitant to allow docs warnings to cause full CI failure, but a lot of sphinx issues are reported only as warnings.

Any thoughts on the options above? I still don't really understand why continueOnError results in a pass for a task, but I guess I'm still leaning toward putting the docs as the last step and turning off continueOnError so it's reported as a failure. The check_diff_size and style_check tasks aren't as important right now.

@j9ac9k j9ac9k marked this pull request as ready for review October 15, 2020 05:11
@j9ac9k
Copy link
Copy Markdown
Member

j9ac9k commented Oct 15, 2020

Taking off WIP status as I'd like to get this merged in, but I'm looking at this a bit more, I too am concerned about azure pipelines reporting failures, but allowing the test suite to continue on...

@j9ac9k
Copy link
Copy Markdown
Member

j9ac9k commented Oct 15, 2020

@ixjlyons sorry it's taken me so long to read into this, but I'm thinking your second option condition: succeededOrFailed() to the test stage is probably what we want. If the wheel fails to build, we'll get an error, and we shouldn't be surprised that the tests fail then ... I'll implement this diff...

@j9ac9k
Copy link
Copy Markdown
Member

j9ac9k commented Oct 15, 2020

now that I got the test stage to work on succeededOrFailed() I'm actually thinking of removing that condition... primarily reason is if you get a docs/linting failure, you can usually fix it quick, but if you're having to wait out the test suite, that's ~15 minutes before the CI will give you another go (I think we have it setup to stop running if a new push comes in).

EDIT: ok, we have it setup so the CI run aborts if a new commit is pushed on that branch;...k, I'm good w/ the current succeededOrFailed();...

I could make another intermediate stage for the wheel to be build, where to run tests we need the wheel to pass, but not necessarily the other pre-test steps... I think that would satisfy all conditions,

@j9ac9k j9ac9k force-pushed the docs-ci branch 2 times, most recently from 7cbe1d2 to dbe3897 Compare October 15, 2020 06:07
@j9ac9k
Copy link
Copy Markdown
Member

j9ac9k commented Oct 15, 2020

I think this PR is ready for merging, the CI is complaining about PColorMeshItem.py which wasn't even in this branch (guess it's checking against the current status of the master branch?)

@j9ac9k
Copy link
Copy Markdown
Member

j9ac9k commented Oct 15, 2020

I'm going to merge this and then tackel the PColorMesh docs issue, thanks @ixjlyons for getting this PR going!

@j9ac9k j9ac9k merged commit 1f76ac0 into pyqtgraph:master Oct 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants