Skip to content

Commit 3974e02

Browse files
committed
Enable trace feature for subfeatures using it (#3337)
# Objective - It isn't very useful to be able to enable feature `trace_chrome` on its own ## Solution - Enable `trace` feature when enabling `trace_chrome` or `trace_tracy` Co-authored-by: François <8672791+mockersf@users.noreply.github.com>
1 parent e677755 commit 3974e02

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

Cargo.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,8 @@ bevy_gilrs = ["bevy_internal/bevy_gilrs"]
5454
bevy_gltf = ["bevy_internal/bevy_gltf"]
5555
bevy_winit = ["bevy_internal/bevy_winit"]
5656

57-
trace_chrome = ["bevy_internal/trace_chrome"]
58-
trace_tracy = ["bevy_internal/trace_tracy"]
57+
trace_chrome = ["trace", "bevy_internal/trace_chrome"]
58+
trace_tracy = ["trace", "bevy_internal/trace_tracy"]
5959
trace = ["bevy_internal/trace"]
6060
wgpu_trace = ["bevy_internal/wgpu_trace"]
6161

docs/cargo_features.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
|-|-|
2222
|bevy_dynamic_plugin|Plugin for dynamic loading (using [libloading](https://crates.io/crates/libloading)).|
2323
|dynamic|Forces bevy to be dynamically linked, which improves iterative compile times.|
24-
|trace|Enables system tracing (useful in tandem with a feature like trace_chrome).|
24+
|trace|Enables system tracing.|
2525
|trace_chrome|Enables [tracing-chrome](https://github.com/thoren-d/tracing-chrome) as bevy_log output. This allows you to visualize system execution.|
2626
|trace_tracy|Enables [Tracy](https://github.com/wolfpld/tracy) as bevy_log output. This allows `Tracy` to connect to and capture profiling data as well as visualize system execution in real-time, present statistics about system execution times, and more.|
2727
|wgpu_trace|For tracing wgpu.|

docs/profiling.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Bevy has built-in [tracing](https://github.com/tokio-rs/tracing) spans to make i
66

77
### Backend: trace_chrome
88

9-
`cargo run --release --features trace,trace_chrome`
9+
`cargo run --release --features trace_chrome`
1010

1111
After running your app a `json` file in the "chrome tracing format" will be produced. You can open this file in your browser using <https://ui.perfetto.dev>. It will look something like this (make sure you expand `Process 1`):
1212

0 commit comments

Comments
 (0)