Skip to content

Fix multi-line log when inserting a resource multiple times#24376

Merged
alice-i-cecile merged 1 commit into
bevyengine:mainfrom
tylerrussin:fix/single-line-resource-warning-v2
May 21, 2026
Merged

Fix multi-line log when inserting a resource multiple times#24376
alice-i-cecile merged 1 commit into
bevyengine:mainfrom
tylerrussin:fix/single-line-resource-warning-v2

Conversation

@tylerrussin
Copy link
Copy Markdown

Objective

Fixes #24360

Solution

Flattened the multi-line warn!() message in resource.rs using the \ character, preventing literal newlines and indentation from being displayed in log output.

Testing

Created a small program outside the repo that inserts the same resource twice, which triggered the warning and confirmed that the log output now appears on a single line.

@kfc35 kfc35 added D-Trivial Nice and easy! A great choice to get started with Bevy C-Usability A targeted quality-of-life change that makes Bevy easier to use S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it A-Diagnostics Logging, crash handling, error reporting and performance analysis labels May 21, 2026
@alice-i-cecile alice-i-cecile added this pull request to the merge queue May 21, 2026
Merged via the queue into bevyengine:main with commit 9778522 May 21, 2026
47 checks passed
@mockersf mockersf added this to the 0.19 milestone May 21, 2026
mockersf pushed a commit that referenced this pull request May 21, 2026
# Objective

Fixes #24360

## Solution

Flattened the multi-line `warn!()` message in `resource.rs` using the
`\` character, preventing literal newlines and indentation from being
displayed in log output.

## Testing

Created a small program outside the repo that inserts the same resource
twice, which triggered the warning and confirmed that the log output now
appears on a single line.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-Diagnostics Logging, crash handling, error reporting and performance analysis C-Usability A targeted quality-of-life change that makes Bevy easier to use D-Trivial Nice and easy! A great choice to get started with Bevy S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it

Projects

None yet

Development

Successfully merging this pull request may close these issues.

multi line log when inserting a resource multiple times

4 participants