Skip to content
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

all: Include create README in lib.rsso doctests are run #2455

Open
hds opened this issue Feb 3, 2023 · 4 comments
Open

all: Include create README in lib.rsso doctests are run #2455

hds opened this issue Feb 3, 2023 · 4 comments
Assignees

Comments

@hds
Copy link
Contributor

hds commented Feb 3, 2023

Feature Request

Crates

All the crates in the tracing repo (except tracing-mock which is already done).

Motivation

The examples in the README files aren't tested. The README may diverge from the
top level crate documentation in lib.rs for each crate. There is currently a mix of
examples for current vs. future versions of each crate in the README, which may
confuse users.

Proposal

Follow the examples in #2362 and include the full contents of the README
into the docs in lib.rs. As most crates already have documentation in lib.rs,
the two cases will need to be consolidates.

Alternatives

We could also copy and paste the README text into lib.rs, but that's probably
less than ideal.

@davidbarsky
Copy link
Member

davidbarsky commented Feb 3, 2023

For what it's worth, I think we should do this—it would cut down on the documentation burden tremendously.

@hawkw
Copy link
Member

hawkw commented Feb 3, 2023

yup, i've wanted to do this for a while, but haven't had the time to work on it. if you're willing to put a PR together, that would be much appreciated!

@hds
Copy link
Contributor Author

hds commented Feb 3, 2023

Yep, I've got it on my to do list. I remember we discussed this in the PR for the tracing-mock README and I kind of forgot about it for a while. But I remembered again and decided to create an issue this time so I wouldn't forget... again. (-;

@hawkw hawkw assigned hds Feb 3, 2023
@hawkw
Copy link
Member

hawkw commented Feb 3, 2023

Cool, I'll go ahead and assign you, then!

@hawkw hawkw added the kind/docs label Feb 3, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants