bevy/crates/bevy_scene/src
Mike d58ed67fa4
add position to scene errors (#8065)
# Objective

- Fixes https://github.com/bevyengine/bevy/issues/6760
- adds line and position on line info to scene errors

```text
Before:
2023-03-12T22:38:59.103220Z  WARN bevy_asset::asset_server: encountered an error while loading an asset: Expected closing `)`
After:
2023-03-12T22:38:59.103220Z  WARN bevy_asset::asset_server: encountered an error while loading an asset: Expected closing `)` at scenes/test/scene.scn.ron:10:4
```

## Solution

- use span_error to get position info. This is what the ron crate does
internally to get the position info.
562963f887/src/options.rs (L158)

## Changelog

- added line numbers to scene errors

---------

Co-authored-by: Paul Hansen <mail@paul.rs>
2023-03-20 19:29:54 +00:00
..
bundle.rs Add VisibilityBundle and use it to fix gltfs, scenes, and examples (#5335) 2022-07-16 02:47:23 +00:00
dynamic_scene.rs bevy_ecs: ReflectComponentFns without World (#7206) 2023-02-03 05:53:58 +00:00
dynamic_scene_builder.rs bevy_ecs: ReflectComponentFns without World (#7206) 2023-02-03 05:53:58 +00:00
lib.rs Schedule-First: the new and improved add_systems (#8079) 2023-03-18 01:45:34 +00:00
scene.rs Clean up Fetch code (#4800) 2022-10-28 09:25:50 +00:00
scene_loader.rs add position to scene errors (#8065) 2023-03-20 19:29:54 +00:00
scene_spawner.rs Fix various typos (#7096) 2023-01-06 00:43:30 +00:00
serde.rs Fix beta clippy lints (#7154) 2023-01-11 09:51:22 +00:00