-
Notifications
You must be signed in to change notification settings - Fork 37
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
Add API documentation #456
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this! There are several things that should be changed, but it's mostly just the wordings on some pages, but overall great work!
docs/api/advanced/index.rst
Outdated
mcstatus.address | ||
mcstatus.dns |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we really want to make these a part of the public API? These are purely internal tools which don't really have anything to do with obtaining status of minecraft servers. I would rather avoid making these public as it forces us to keep them backwards compatible. I'd put these on the internal page instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I thought that mcstatus.dns is a part of Public API, maybe I just remember #203 wrong. Although, in the #203 description, it's clearly mentioned that this is a part of Public API.
Fair, I might've originally intended it to be a part of the public API, however I'm not sure if it actually should be. I'd vote for moving it into the internal, and if someone really wants it they can still technically use it as an internal feature, without us guaranteeing backwards compatibility there.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed Address
from here in this force push.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's also remove the dns module, as I said, it probably shouldn't be a part of the public API.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would like to hear @kevinkjt2000's mind also.
https://discord.com/channels/936788458939224094/938623566964981802/1061536418175918141
9a33ad9
to
7ac4014
Compare
Documentation build will be fixed after #458. |
Note that documentation in general is not finished. This just adds the skeleton for the API docs, I also didn't adapt docstrings for Sphinx style yet, it will be a separated PR.
To see the docs:
poetry install --with docs
cd docs
make html
_build/html/index.html
in your browser.I also used built-in Sphinx type hints support (see discussion in Discord) because the second variant was buggy. Although, I like the result.