Skip to content

Conversation

@alcaeus
Copy link
Member

@alcaeus alcaeus commented Oct 11, 2022

This PR adds a build step to build documentation. This can be used in lieu of building documentation locally as python 2 is no longer available on many platforms. I was not able to make giza make publish exit with a non-zero exit code, even when using a wrong filename to link to a file. For now this means we'll have to verify the docs build manually, but it's better than not being able to run docs at all. The second commit fixes all current warnings.

The built documentation is uploaded as a build artefact to the Docs workflow, accessible through the actions tab.

@alcaeus alcaeus requested a review from jmikola October 11, 2022 11:32
@alcaeus alcaeus self-assigned this Oct 11, 2022
--------

MongoDB stores data records as BSON documents. BSON is a binary representation
of :term:`JSON` documents, though it contains more data types than JSON. For the
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Apparently, this term isn't defined and the current docs don't render this in a special way, so I removed it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. I've seen this error before but never traced it back to this line. I agree this serves no purpose.

It could be something that only builds correctly with the docs team's build tools, since those pull in additional resources used by the server manual (or did if they no longer use Giza).

- :manual:`Change Streams </changeStreams>` documentation in the MongoDB manual
- :manual:`Change Events </reference/change-events/>` documentation in the
MongoDB manual
MongoDB manual
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file (and the next) were lacking a trailing newline.

with:
python-version: '2.7'

# The requirements file installs urllib3 with an incompatible version; we replace it with one that works
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this worth a PR to mongodb/docs-tools? Worst case it doesn't get merged.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Created mongodb/docs-tools#599 to update this.

run: "rsync -a library/docs/ docs/source/"

- name: "Run Giza"
run: "giza make publish"
Copy link
Member

@jmikola jmikola Oct 11, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@i80and: Any chance you know of a way to get giza to return a non-zero exit code on an erroneous docs build?

Quoting @alcaeus's comment in the OP:

I was not able to make giza make publish exit with a non-zero exit code, even when using a wrong filename to link to a file.

@alcaeus alcaeus force-pushed the add-docs-build-to-ci branch from c91d4d1 to 3881515 Compare October 12, 2022 07:17
@alcaeus alcaeus merged commit f7ba251 into mongodb:master Oct 12, 2022
@alcaeus alcaeus deleted the add-docs-build-to-ci branch October 12, 2022 07:43
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