`asset_server.load_folder` never creates a `LoadedFolder` asset if _any_ asset contained errors while loading
- Dominant language
- Rust
- Stars
- 48.2k
- Forks
- 4.8k
- Avg merge
- 3d 16h
- Merged PRs (30d)
- 171
Description
## Bevy version
0.12.0
## What you did
Had a typo in a ron custom asset such that `ron::de::from_bytes(&bytes)?` returned an error
## What went wrong
- what were you expecting?
`LoadedFolder` asset would show up with most handles being in `LoadState::Loaded` and the one typo resulting in a `LoadState::Failed`
Error messages would be output from failed load(s)
- what actually happened?
`LoadedFolder` asset for the folder containing one broken asset and many valid assets was never created
No errors are sent to the console
## Additional information
I also noticed that `LoadedFolder` assets aren't created until all handles within them have completely reached `LoadState::Loaded` even when everything is going correctly, so you can't check for the progress of the individual assets being loaded. Seems related, but at the very least I think it needs to be created when all handles reach either `LoadState::Loaded || LoadState::Failed`
Contributor guide
Research direction
Start at asset_server.load_folder and trace how LoadedFolder creation handles child LoadState values. Reproduce the case with a custom RON asset containing a deserialization error and several valid assets; done means the folder asset is created when children reach Loaded or Failed, failed-load errors are reported, and individual loading progress remains observable.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- game-dev
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100