Skip to content

Commit

Permalink
Revert "Use gh-pages hosted rust doc while doc.rs docs are broken (#8166
Browse files Browse the repository at this point in the history
)"

This reverts commit cf9299d.
  • Loading branch information
emilk authored Nov 21, 2024
1 parent 193e1bb commit 27da092
Show file tree
Hide file tree
Showing 167 changed files with 197 additions and 199 deletions.
2 changes: 1 addition & 1 deletion BUILD.md
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ High-level documentation for Rerun can be found at [http://rerun.io/docs](http:/

- 🌊 [C++ API docs](https://ref.rerun.io/docs/cpp) are built with `doxygen` and hosted on GitHub. Use `pixi run -e cpp cpp-docs` to build them locally. For details on the C++ doc-system, see [Writing Docs](rerun_cpp/docs/writing_docs.md).
- 🐍 [Python API docs](https://ref.rerun.io/docs/python) are built via `mkdocs` and hosted on GitHub. For details on the Python doc-system, see [Writing Docs](rerun_py/docs/writing_docs.md).
- 🦀 [Rust API docs](https://ref.rerun.io/docs/rust/stable) are hosted on <https://ref.rerun.io/docs/rust/stable>. You can build them locally with: `cargo doc --all-features --no-deps --open`.
- 🦀 [Rust API docs](https://docs.rs/rerun/) are hosted on <https://docs.rs/rerun/>. You can build them locally with: `cargo doc --all-features --no-deps --open`.

## Building for the web

Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ This can both greatly simplify logging code and drastically improve performance
API documentation:
* 🐍 [Python `send_columns` docs](https://ref.rerun.io/docs/python/stable/common/columnar_api/#rerun.send_columns)
* 🌊 [C++ `send_columns` docs](https://ref.rerun.io/docs/cpp/stable/classrerun_1_1RecordingStream.html#ad17571d51185ce2fc2fc2f5c3070ad65)
* 🦀 [Rust `send_columns` docs](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.send_columns)
* 🦀 [Rust `send_columns` docs](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.send_columns)

API usage examples:
<details>
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ You should now be able to run `rerun --help` in any terminal.
- ⚙️ [Examples](http://rerun.io/examples)
- 🌊 [C++ API docs](https://ref.rerun.io/docs/cpp)
- 🐍 [Python API docs](https://ref.rerun.io/docs/python)
- 🦀 [Rust API docs](https://ref.rerun.io/docs/rust/stable)
- 🦀 [Rust API docs](https://docs.rs/rerun/)
- ⁉️ [Troubleshooting](https://www.rerun.io/docs/getting-started/troubleshooting)


Expand Down
4 changes: 1 addition & 3 deletions crates/build/re_types_builder/src/codegen/docs/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -381,9 +381,7 @@ fn list_links(is_unreleased: bool, page: &mut String, object: &Object) {

putln!(
page,
// TODO(#8165): docs.rs/rerun is broken right now
// " * 🦀 [Rust API docs for `{}`](https://docs.rs/rerun/latest/rerun/{}/{}.{}.html{speculative_marker})",
" * 🦀 [Rust API docs for `{}`](https://ref.rerun.io/docs/rust/stable/rerun/{}/{}.{}.html{speculative_marker})",
" * 🦀 [Rust API docs for `{}`](https://docs.rs/rerun/latest/rerun/{}/{}.{}.html{speculative_marker})",
object.name,
object.kind.plural_snake_case(),
if object.is_struct() { "struct" } else { "enum" },
Expand Down
4 changes: 1 addition & 3 deletions crates/top/rerun-cli/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@ Run `rerun --help` for more.
## What is Rerun?
- [Examples](https://github.com/rerun-io/rerun/tree/latest/examples/rust)
- [High-level docs](http://rerun.io/docs)
<!-- TODO(#8165): docs.rs/rerun is broken right now -->
<!-- - [Rust API docs](https://ref.rerun.io/docs/rust/stable) -->
- [Rust API docs](https://ref.rerun.io/docs/rust/stable/rerun/)
- [Rust API docs](https://docs.rs/rerun/)
- [Troubleshooting](https://www.rerun.io/docs/getting-started/troubleshooting)


Expand Down
6 changes: 2 additions & 4 deletions crates/top/rerun/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

<h1 align="center">
<a href="https://crates.io/crates/rerun"> <img alt="Latest version" src="https://img.shields.io/crates/v/rerun.svg"> </a>
<a href="https://docs.rs/rerun"> <img alt="Documentation" src="https://ref.rerun.io/docs/rust/stablebadge.svg"> </a>
<a href="https://docs.rs/rerun"> <img alt="Documentation" src="https://docs.rs/rerun/badge.svg"> </a>
<a href="https://github.com/rerun-io/rerun/blob/main/LICENSE-MIT"> <img alt="MIT" src="https://img.shields.io/badge/license-MIT-blue.svg"> </a>
<a href="https://github.com/rerun-io/rerun/blob/main/LICENSE-APACHE"> <img alt="Apache" src="https://img.shields.io/badge/license-Apache-blue.svg"> </a>
<a href="https://discord.gg/Gcm8BbTaAj"> <img alt="Rerun Discord" src="https://img.shields.io/discord/1062300748202921994?label=Rerun%20Discord"> </a>
Expand All @@ -32,9 +32,7 @@ rec.log("image", &rerun::archetypes::Image::new(image))?;
## Getting started
- [Examples](https://github.com/rerun-io/rerun/tree/latest/examples/rust)
- [High-level docs](http://rerun.io/docs)
<!-- TODO(#8165): docs.rs/rerun is broken right now -->
<!-- - [Rust API docs](https://ref.rerun.io/docs/rust/stable) -->
- [Rust API docs](https://ref.rerun.io/docs/rust/stable/rerun/)
- [Rust API docs](https://docs.rs/rerun/)
- [Troubleshooting](https://www.rerun.io/docs/getting-started/troubleshooting)

## Library
Expand Down
4 changes: 2 additions & 2 deletions docs/content/concepts/annotation-context.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ The Annotation Context is defined as a list of Class Descriptions that define ho
Annotation contexts are logged with:

* Python: 🐍[`rr.AnnotationContext`](https://ref.rerun.io/docs/python/stable/common/archetypes/#rerun.archetypes.AnnotationContext)
* Rust: 🦀[`rerun::AnnotationContext`](https://ref.rerun.io/docs/rust/stable/rerun/archetypes/struct.AnnotationContext.html#)
* Rust: 🦀[`rerun::AnnotationContext`](https://docs.rs/rerun/latest/rerun/archetypes/struct.AnnotationContext.html#)

snippet: tutorials/annotation-context

Expand All @@ -72,7 +72,7 @@ By default, Rerun will automatically assign colors to each class id, but by defi
you can explicitly determine the color of each class.

* Python: [`rr.SegmentationImage`](https://ref.rerun.io/docs/python/stable/common/archetypes/#rerun.archetypes.SegmentationImage)
* Rust: Log a [`rerun::SegmentationImage`](https://ref.rerun.io/docs/rust/stable/rerun/archetypes/struct.SegmentationImage.html)
* Rust: Log a [`rerun::SegmentationImage`](https://docs.rs/rerun/latest/rerun/archetypes/struct.SegmentationImage.html)

<picture>
<source media="(max-width: 480px)" srcset="https://static.rerun.io/segmentation_image/f48e7db9a1253f35b55205acd55d4b84ab1d8434/480w.png">
Expand Down
4 changes: 2 additions & 2 deletions docs/content/concepts/app-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ Dataflow:
Reference:
* [SDK operating modes: `connect`](../reference/sdk/operating-modes.md#connect)
* [🐍 Python `connect`](https://ref.rerun.io/docs/python/0.19.0/common/initialization_functions/#rerun.connect)
* [🦀 Rust `connect`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStreamBuilder.html#method.connect)
* [🦀 Rust `connect`](https://docs.rs/rerun/latest/rerun/struct.RecordingStreamBuilder.html#method.connect)
* [🌊 C++ `connect`](https://ref.rerun.io/docs/cpp/stable/classrerun_1_1RecordingStream.html#aef3377ffaa2441b906d2bac94dd8fc64)

### Asynchronous workflow
Expand Down Expand Up @@ -125,7 +125,7 @@ Dataflow:
Reference:
* [SDK operating modes: `save`](../reference/sdk/operating-modes.md#save)
* [🐍 Python `save`](https://ref.rerun.io/docs/python/0.19.0/common/initialization_functions/#rerun.save)
* [🦀 Rust `save`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStreamBuilder.html#method.save)
* [🦀 Rust `save`](https://docs.rs/rerun/latest/rerun/struct.RecordingStreamBuilder.html#method.save)
* [🌊 C++ `save`](https://ref.rerun.io/docs/cpp/stable/classrerun_1_1RecordingStream.html#a555a7940a076c93d951de5b139d14918)

<!--
Expand Down
2 changes: 1 addition & 1 deletion docs/content/concepts/apps-and-recordings.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Different recordings (i.e. different _Recording IDs_) will share the same bluepr

Check out the API to learn more about SDK initialization:
* [🐍 Python](https://ref.rerun.io/docs/python/stable/common/initialization_functions/#rerun.init)
* [🦀 Rust](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStreamBuilder.html#method.new)
* [🦀 Rust](https://docs.rs/rerun/latest/rerun/struct.RecordingStreamBuilder.html#method.new)
* [🌊 C++](https://ref.rerun.io/docs/cpp/stable/classrerun_1_1RecordingStream.html#abda6202900fa439fe5c27f7aa0d1105a)


Expand Down
2 changes: 1 addition & 1 deletion docs/content/getting-started/data-in/open-any-file.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ With the exception of `rrd` files that can be streamed from an HTTP URL (e.g. `r

## Logging file contents from the SDK

To log the contents of a file from the SDK you can use the `log_file_from_path` and `log_file_from_contents` methods ([C++](https://ref.rerun.io/docs/cpp/stable/classrerun_1_1RecordingStream.html#a8f253422a7adc2a19b89d1538c05bcac), [Python](https://ref.rerun.io/docs/python/stable/common/other_classes_and_functions/#rerun.log_file_from_path), [Rust](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.log_file_from_path)) and the associated examples ([C++](https://github.com/rerun-io/rerun/blob/main/examples/cpp/log_file/main.cpp), [Python](https://github.com/rerun-io/rerun/blob/main/examples/python/log_file/log_file.py), [Rust](https://github.com/rerun-io/rerun/blob/main/examples/rust/log_file/src/main.rs)).
To log the contents of a file from the SDK you can use the `log_file_from_path` and `log_file_from_contents` methods ([C++](https://ref.rerun.io/docs/cpp/stable/classrerun_1_1RecordingStream.html#a8f253422a7adc2a19b89d1538c05bcac), [Python](https://ref.rerun.io/docs/python/stable/common/other_classes_and_functions/#rerun.log_file_from_path), [Rust](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.log_file_from_path)) and the associated examples ([C++](https://github.com/rerun-io/rerun/blob/main/examples/cpp/log_file/main.cpp), [Python](https://github.com/rerun-io/rerun/blob/main/examples/python/log_file/log_file.py), [Rust](https://github.com/rerun-io/rerun/blob/main/examples/rust/log_file/src/main.rs)).

Note: when calling these APIs from the SDK, the data will be loaded by the process running the SDK, not the Viewer!

Expand Down
26 changes: 15 additions & 11 deletions docs/content/getting-started/data-in/rust.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ Checkout `rerun --help` for more options.

## Initializing the SDK

To get going we want to create a [`RecordingStream`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html):
We can do all of this with the [`rerun::RecordingStreamBuilder::new`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStreamBuilder.html#method.new) function which allows us to name the dataset we're working on by setting its [`ApplicationId`](https://ref.rerun.io/docs/rust/stable/rerun/struct.ApplicationId.html).
We then connect it to the already running Viewer via [`connect`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStreamBuilder.html#method.connect), returning the `RecordingStream` upon success.
To get going we want to create a [`RecordingStream`](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html):
We can do all of this with the [`rerun::RecordingStreamBuilder::new`](https://docs.rs/rerun/latest/rerun/struct.RecordingStreamBuilder.html#method.new) function which allows us to name the dataset we're working on by setting its [`ApplicationId`](https://docs.rs/rerun/latest/rerun/struct.ApplicationId.html).
We then connect it to the already running Viewer via [`connect`](https://docs.rs/rerun/latest/rerun/struct.RecordingStreamBuilder.html#method.connect), returning the `RecordingStream` upon success.

```rust
fn main() -> Result<(), Box<dyn std::error::Error>> {
Expand All @@ -72,7 +72,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
}
```

Among other things, a stable [`ApplicationId`](https://ref.rerun.io/docs/rust/stable/rerun/struct.ApplicationId.html) will make it so the [Rerun Viewer](../../reference/viewer/overview.md) retains its UI state across runs for this specific dataset, which will make our lives much easier as we iterate.
Among other things, a stable [`ApplicationId`](https://docs.rs/rerun/latest/rerun/struct.ApplicationId.html) will make it so the [Rerun Viewer](../../reference/viewer/overview.md) retains its UI state across runs for this specific dataset, which will make our lives much easier as we iterate.

Check out the reference to learn more about how Rerun deals with [applications and recordings](../../concepts/apps-and-recordings.md).

Expand Down Expand Up @@ -120,7 +120,9 @@ This tiny snippet of code actually holds much more than meets the eye…

### Archetypes

The easiest way to log geometric primitives is the use the [`RecordingStream::log`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.log) method with one of the built-in archetype class, such as [`Points3D`](https://ref.rerun.io/docs/rust/stable/rerun/struct.Points3D.html). Archetypes take care of building batches
<!-- TODO(andreas): UPDATE DOC LINKS -->

The easiest way to log geometric primitives is the use the [`RecordingStream::log`](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.log) method with one of the built-in archetype class, such as [`Points3D`](https://docs.rs/rerun/latest/0.9.0-alpha.10/struct.Points3D.html). Archetypes take care of building batches
of components that are recognized and correctly displayed by the Rerun viewer.

### Components
Expand All @@ -131,9 +133,11 @@ cases, it's possible to add custom components to archetypes, or even log entirel
archetypes altogether.
For more information on how the Rerun data model works, refer to our section on [Entities and Components](../../concepts/entity-component.md).

Notably, the [`RecordingStream::log`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.log) method
Notably, the [`RecordingStream::log`](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.log) method

<!-- TODO(andreas): UPDATE DOC LINKS -->

will handle any data type that implements the [`AsComponents`](https://ref.rerun.io/docs/rust/stable/rerun/trait.AsComponents.html) trait, making it easy to add your own data.
will handle any data type that implements the [`AsComponents`](https://docs.rs/rerun/latest/rerun/trait.AsComponents.html) trait, making it easy to add your own data.
For more information on how to supply your own components see [Use custom data](../../howto/extend/custom-data.md).

### Entities & hierarchies
Expand Down Expand Up @@ -261,7 +265,7 @@ for i in 0..400 {
}
```

First we use [`RecordingStream::set_time_seconds`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.set_time_seconds) to declare our own custom `Timeline` and set the current timestamp.
First we use [`RecordingStream::set_time_seconds`](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.set_time_seconds) to declare our own custom `Timeline` and set the current timestamp.
You can add as many timelines and timestamps as you want when logging data.

⚠️ If you run this code as is, the result will be.. surprising: the beads are animating as expected, but everything we've logged until that point is gone! ⚠️
Expand Down Expand Up @@ -330,7 +334,7 @@ Sometimes, sending the data over the network is not an option. Maybe you'd like

Rerun has you covered:

- Use [`RecordingStream::save`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.save) to stream all logging data to disk.
- Use [`RecordingStream::save`](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.save) to stream all logging data to disk.
- Visualize it via `rerun path/to/recording.rrd`

You can also save a recording (or a portion of it) as you're visualizing it, directly from the viewer.
Expand All @@ -339,7 +343,7 @@ You can also save a recording (or a portion of it) as you're visualizing it, dir

### Spawning the Viewer from your process

If the Rerun Viewer is [installed](../installing-viewer.md) and available in your `PATH`, you can use [`RecordingStream::spawn`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.spawn) to automatically start a Viewer in a new process and connect to it over TCP.
If the Rerun Viewer is [installed](../installing-viewer.md) and available in your `PATH`, you can use [`RecordingStream::spawn`](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.spawn) to automatically start a Viewer in a new process and connect to it over TCP.
If an external Viewer was already running, `spawn` will connect to that one instead of spawning a new one.

```rust
Expand All @@ -353,7 +357,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
}
```

Alternatively, you can use [`rerun::native_viewer::show`](https://ref.rerun.io/docs/rust/stable/rerun/native_viewer/fn.show.html) to start a Viewer on the main thread (for platform-compatibility reasons) and feed it data from memory.
Alternatively, you can use [`rerun::native_viewer::show`](https://docs.rs/rerun/latest/rerun/native_viewer/fn.show.html) to start a Viewer on the main thread (for platform-compatibility reasons) and feed it data from memory.
This requires the `native_viewer` feature to be enabled in `Cargo.toml`:

```toml
Expand Down
2 changes: 1 addition & 1 deletion docs/content/howto/logging/custom-data.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ rr.log(
)
```

You can also create your own component by implementing the `AsComponents` [Python protocol](https://ref.rerun.io/docs/python/0.9.0/common/interfaces/#rerun.AsComponents) or [Rust trait](https://ref.rerun.io/docs/rust/stable/rerun/trait.AsComponents.html), which means implementing the function, `as_component_batches()`.
You can also create your own component by implementing the `AsComponents` [Python protocol](https://ref.rerun.io/docs/python/0.9.0/common/interfaces/#rerun.AsComponents) or [Rust trait](https://docs.rs/rerun/latest/rerun/trait.AsComponents.html), which means implementing the function, `as_component_batches()`.

## Remapping to a Rerun archetype
Let's start with a simple example where you have your own point cloud class that is perfectly representable as a Rerun archetype.
Expand Down
2 changes: 1 addition & 1 deletion docs/content/howto/logging/send-columns.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ In contrast to the `log` function, `send_columns` does NOT add any other timelin
API docs of `send_columns`:
* [🌊 C++](https://ref.rerun.io/docs/cpp/stable/classrerun_1_1RecordingStream.html#ad17571d51185ce2fc2fc2f5c3070ad65)
* [🐍 Python](https://ref.rerun.io/docs/python/stable/common/columnar_api/#rerun.send_columns)
* [🦀 Rust](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.send_columns)
* [🦀 Rust](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.send_columns)


### Using `send_columns` for logging scalars
Expand Down
2 changes: 1 addition & 1 deletion docs/content/howto/visualization/reuse-blueprints.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ The interactive way is to import the blueprint file directly into the Rerun view

The programmatic way works by calling `log_file_from_path`:
* [🐍 Python `log_file_from_path`](https://ref.rerun.io/docs/python/stable/common/logging_functions/#rerun.log_file_from_path)
* [🦀 Rust `log_file_from_path`](https://ref.rerun.io/docs/rust/stable/rerun/struct.RecordingStream.html#method.log_file_from_path)
* [🦀 Rust `log_file_from_path`](https://docs.rs/rerun/latest/rerun/struct.RecordingStream.html#method.log_file_from_path)
* [🌊 C++ `log_file_from_path`](https://ref.rerun.io/docs/cpp/stable/classrerun_1_1RecordingStream.html#a20798d7ea74cce5c8174e5cacd0a2c47)

This method allows you to log any file that contains data that Rerun understands (in this case, blueprint data) as part of your current recording:
Expand Down
2 changes: 1 addition & 1 deletion docs/content/reference/data-loaders/overview.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ The Rerun Viewer/SDK will then automatically load the data streamed to the exter
</picture>

Like any other `DataLoader`, an external loader will be notified of all file openings, unconditionally.
To indicate that it does not support a given file, the loader has to exit with a [dedicated status code](https://ref.rerun.io/docs/rust/stable/rerun/constant.EXTERNAL_DATA_LOADER_INCOMPATIBLE_EXIT_CODE.html).
To indicate that it does not support a given file, the loader has to exit with a [dedicated status code](https://docs.rs/rerun/latest/rerun/constant.EXTERNAL_DATA_LOADER_INCOMPATIBLE_EXIT_CODE.html).

When the Viewer and/or SDK executes an external loader, it will pass to it a set of recommended settings in the form of CLI parameters (in addition to the file path to be loaded, which is passed as the one and only positional argument):

Expand Down
Loading

0 comments on commit 27da092

Please sign in to comment.