-
Notifications
You must be signed in to change notification settings - Fork 653
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 rustdoc to connect crate #1455
base: dev
Are you sure you want to change the base?
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.
Copilot reviewed 5 out of 11 changed files in this pull request and generated 1 comment.
Files not reviewed (6)
- CHANGELOG.md: Evaluated as low risk
- connect/README.md: Evaluated as low risk
- connect/src/lib.rs: Evaluated as low risk
- connect/src/model.rs: Evaluated as low risk
- connect/src/state/metadata.rs: Evaluated as low risk
- src/main.rs: Evaluated as low risk
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.
Quite the effort to get everything documented!
When you're looking for anyone's review, you can specifically request / add them as reviewers and keep the assignee as yourself. |
Okay will do! You just said in another message that I should assigning you, but I suppose I mistook assigning to the PR with review assigning. |
Oh and big thanks for the review @roderickvd :D |
fd6de96
to
bed00a6
Compare
bed00a6
to
1416fd2
Compare
connect/README.md
Outdated
when awaited. | ||
|
||
To get an understanding how to handle the `SpircTask`, it is recommended to take look | ||
at the code of the `librespot` binary. As the [`src/main.rs`](https://github.com/librespot-org/librespot/blob/dev/src/main.rs#L1943) |
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.
Maybe link this to a specific commit, so we can be sure the reference to this line remains as we expect?
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.
Hmm, fair point. I wanted to point to up-to-date code, so that the reference doesn't get outdated. But I can also see the appeal of a specific commit. In the end it's probably better to point in a general direction, then an outdated I would say. Who knows when these initial docs may run out of sync.
But the same argument can probably be made if someone refactors the main.rs
file into smaller files. If you have a strong stance on a specific commit I will change it, otherwise I would keep it as is.
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.
Could we extract it into a new example?
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 added a minimal compilable version here in the README (so that you have an example on docs.rs). But for a greater picture I just point to a working version, which is as currently the binary.
But yeah in general an own example would be technically better... Yeah why not! I had the thought initially, but wanted to only provided an example in the README (probably laziness). Tho it's probably better to point to a static point, as the example will hopefully not change as the binary will.
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 was wondering if there is any rust tooling that takes examples and inserts them into rustdoc automatically when you publish the crate. I think Python has stuff like that. I did find found rust-lang/rust#88791 which looks cool.
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.
Well actually there was already an example I didn't fully noticed so far. I updated it a bit and referenced it in the README now.
I think I initially tried to enforce rustdoc on the whole project, but that just is in insane task at this stage.
Well anyhow... I got around to add rustdoc for the connect crate and additionally a cleanup of the exposed items, so that only the necessary are exposed.
I also had to change up the
CHANGELOG.md
as some previous entries where are out of that with the cleanup changes.