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

Document all public item in re_types #6146

Merged
merged 26 commits into from Apr 29, 2024
Merged

Document all public item in re_types #6146

merged 26 commits into from Apr 29, 2024

Conversation

emilk
Copy link
Member

@emilk emilk commented Apr 29, 2024

What

This is our public API, and keeping it well-documented seems like a low bar.

In some places it may seem unnecessary (e.g. describing what a new function does, or what Angle::Degrees means), but enforcing #[allow(missing_docs)] is the only way I know to remind us (and other contributors) to always consider documentation.

You can opt-out using #![allow(missing_docs)].

While fixing the docs I found a few weird pieces of code that I also fixed.

Before

Screenshot 2024-04-29 at 09 04 28 Screenshot 2024-04-29 at 09 04 22

After

Screenshot 2024-04-29 at 09 03 34 Screenshot 2024-04-29 at 09 03 56

Checklist

  • I have read and agree to Contributor Guide and the Code of Conduct
  • I've included a screenshot or gif (if applicable)
  • I have tested the web demo (if applicable):
  • The PR title and labels are set such as to maximize their usefulness for the next release's CHANGELOG
  • If applicable, add a new check to the release checklist!

To run all checks from main, comment on the PR with @rerun-bot full-check.

@emilk emilk added 📖 documentation Improvements or additions to documentation 🦀 Rust API Rust logging API labels Apr 29, 2024
Copy link

github-actions bot commented Apr 29, 2024

Deployed docs

Commit Link
f4c1686 https://landing-cavwr1hqk-rerun.vercel.app/docs

crates/re_types/definitions/rerun/datatypes/angle.fbs Outdated Show resolved Hide resolved
define_coordinates!(LEFT_HAND_Y_DOWN => (Right, Down, Back));
define_coordinates!(LEFT_HAND_Z_UP => (Right, Back, Up));
define_coordinates!(LEFT_HAND_Z_DOWN => (Right, Forward, Down));
define_coordinates!("X=Up, Y=Left, Z=Forward", ULF => (Up, Left, Forward));
Copy link
Member

Choose a reason for hiding this comment

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

oof, the macro wasn't able to extract that?

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 is generated code

crates/re_types/src/components/position2d_ext.rs Outdated Show resolved Hide resolved
crates/re_types/src/components/position3d_ext.rs Outdated Show resolved Hide resolved
crates/re_types/src/components/transform3d_ext.rs Outdated Show resolved Hide resolved
crates/re_types/src/datatypes/quaternion_ext.rs Outdated Show resolved Hide resolved
crates/re_types/src/datatypes/tensor_data_ext.rs Outdated Show resolved Hide resolved
crates/re_types/src/tensor_data.rs Outdated Show resolved Hide resolved
@emilk emilk merged commit 734187c into main Apr 29, 2024
39 checks passed
@emilk emilk deleted the emilk/document-re_types branch April 29, 2024 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📖 documentation Improvements or additions to documentation include in changelog 🦀 Rust API Rust logging API
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants