Skip to content

Commit

Permalink
Merge branch 'main' into NoSTDBevyReflect
Browse files Browse the repository at this point in the history
  • Loading branch information
alice-i-cecile authored Dec 3, 2024
2 parents 28a32fb + f375422 commit c5effe6
Show file tree
Hide file tree
Showing 338 changed files with 7,018 additions and 3,366 deletions.
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/performance_regression.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name: Performance Regression
about: Bevy running slowly after upgrading? Report a performance regression.
title: ''
labels: C-Bug, C-Performance, C-Regression, S-Needs-Triage
labels: C-Bug, C-Performance, P-Regression, S-Needs-Triage
assignees: ''
---

Expand Down
5 changes: 0 additions & 5 deletions .github/example-run/alien_cake_addict.ron

This file was deleted.

8 changes: 0 additions & 8 deletions .github/example-run/breakout.ron

This file was deleted.

6 changes: 6 additions & 0 deletions .github/example-run/testbed_ui.ron
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
(
events: [
(100, Screenshot),
(200, AppExit),
]
)
28 changes: 12 additions & 16 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,7 @@ jobs:
run: cargo run -p ci -- lints

miri:
# Explicitly use macOS 14 to take advantage of M1 chip.
runs-on: macos-14
runs-on: macos-latest
timeout-minutes: 60
steps:
- uses: actions/checkout@v4
Expand Down Expand Up @@ -127,7 +126,7 @@ jobs:
- name: Check Compile
# See tools/ci/src/main.rs for the commands this runs
run: cargo run -p ci -- compile

check-compiles-no-std:
runs-on: ubuntu-latest
timeout-minutes: 30
Expand Down Expand Up @@ -231,10 +230,10 @@ jobs:
- name: Taplo info
if: failure()
run: |
echo 'To fix toml fmt, please run `taplo fmt`'
echo 'To check for a diff, run `taplo fmt --check --diff'
echo 'To fix toml fmt, please run `taplo fmt`.'
echo 'To check for a diff, run `taplo fmt --check --diff`.'
echo 'You can find taplo here: https://taplo.tamasfe.dev/'
echo 'Or if you use VSCode, use the `Even Better Toml` extension with 2 spaces'
echo 'Or if you use VSCode, use the `Even Better Toml` extension.'
echo 'You can find the extension here: https://marketplace.visualstudio.com/items?itemName=tamasfe.even-better-toml'
typos:
Expand All @@ -243,7 +242,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Check for typos
uses: crate-ci/[email protected].0
uses: crate-ci/[email protected].3
- name: Typos info
if: failure()
run: |
Expand All @@ -254,19 +253,14 @@ jobs:
echo 'You can find the extension here: https://marketplace.visualstudio.com/items?itemName=tekumara.typos-vscode'
run-examples-macos-metal:
# Explicitly use macOS 14 to take advantage of M1 chip.
runs-on: macos-14
runs-on: macos-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- name: Disable audio
# Disable audio through a patch. on github m1 runners, audio timeouts after 15 minutes
run: git apply --ignore-whitespace tools/example-showcase/disable-audio.patch
- name: Build bevy
# this uses the same command as when running the example to ensure build is reused
run: |
TRACE_CHROME=trace-alien_cake_addict.json CI_TESTING_CONFIG=.github/example-run/alien_cake_addict.ron cargo build --example alien_cake_addict --features "bevy_ci_testing,trace,trace_chrome"
- name: Run examples
run: |
for example in .github/example-run/*.ron; do
Expand Down Expand Up @@ -301,7 +295,7 @@ jobs:
with:
name: example-run-macos
path: example-run/

check-doc:
runs-on: ubuntu-latest
timeout-minutes: 30
Expand All @@ -316,7 +310,9 @@ jobs:
~/.cargo/git/db/
target/
key: ${{ runner.os }}-check-doc-${{ hashFiles('**/Cargo.toml') }}
- uses: dtolnay/rust-toolchain@stable
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ env.NIGHTLY_TOOLCHAIN }}
- name: Install Linux dependencies
uses: ./.github/actions/install-linux-deps
with:
Expand All @@ -327,7 +323,7 @@ jobs:
run: cargo run -p ci -- doc
env:
CARGO_INCREMENTAL: 0
RUSTFLAGS: "-C debuginfo=0"
RUSTFLAGS: "-C debuginfo=0 --cfg docsrs_dep"
# This currently report a lot of false positives
# Enable it again once it's fixed - https://github.com/bevyengine/bevy/issues/1983
# - name: Installs cargo-deadlinks
Expand Down
24 changes: 2 additions & 22 deletions .github/workflows/validation-jobs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
with:
path: |
target
key: ${{ runner.os }}-ios-install-${{ matrix.toolchain }}-${{ hashFiles('**/Cargo.lock') }}
key: ${{ runner.os }}-ios-install-${{ hashFiles('**/Cargo.lock') }}

# TODO: remove x86 target once it always run on arm GitHub runners
- name: Add iOS targets
Expand Down Expand Up @@ -101,10 +101,6 @@ jobs:
target/
key: ${{ runner.os }}-cargo-run-examples-${{ hashFiles('**/Cargo.toml') }}
- uses: dtolnay/rust-toolchain@stable
- name: Build bevy
# this uses the same command as when running the example to ensure build is reused
run: |
TRACE_CHROME=trace-alien_cake_addict.json CI_TESTING_CONFIG=.github/example-run/alien_cake_addict.ron cargo build --example alien_cake_addict --features "bevy_ci_testing,trace,trace_chrome"
- name: Run examples
run: |
for example in .github/example-run/*.ron; do
Expand Down Expand Up @@ -155,11 +151,6 @@ jobs:
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- name: Build bevy
shell: bash
# this uses the same command as when running the example to ensure build is reused
run: |
WGPU_BACKEND=dx12 TRACE_CHROME=trace-alien_cake_addict.json CI_TESTING_CONFIG=.github/example-run/alien_cake_addict.ron cargo build --example alien_cake_addict --features "bevy_ci_testing,trace,trace_chrome"
- name: Run examples
shell: bash
run: |
Expand Down Expand Up @@ -192,17 +183,6 @@ jobs:
name: example-run-windows
path: example-run/

compare-windows-screenshots:
name: Compare Windows screenshots
needs: [run-examples-on-windows-dx12]
uses: ./.github/workflows/send-screenshots-to-pixeleagle.yml
with:
commit: ${{ github.sha }}
branch: ${{ github.ref_name }}
artifact: screenshots-windows
os: windows
secrets: inherit

run-examples-on-wasm:
if: ${{ github.event_name == 'merge_group' }}
runs-on: ubuntu-22.04
Expand Down Expand Up @@ -244,7 +224,7 @@ jobs:
- name: First Wasm build
run: |
cargo build --release --example ui --target wasm32-unknown-unknown
cargo build --release --example testbed_ui --target wasm32-unknown-unknown
- name: Run examples
shell: bash
Expand Down
26 changes: 4 additions & 22 deletions .github/workflows/weekly.yml
Original file line number Diff line number Diff line change
Expand Up @@ -59,31 +59,13 @@ jobs:
# See tools/ci/src/main.rs for the commands this runs
run: cargo run -p ci -- compile

check-doc:
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@beta
- name: Install Linux dependencies
uses: ./.github/actions/install-linux-deps
with:
wayland: true
xkb: true
- name: Build and check docs
# See tools/ci/src/main.rs for the commands this runs
run: cargo run -p ci -- doc
env:
CARGO_INCREMENTAL: 0
RUSTFLAGS: "-C debuginfo=0"

open-issue:
name: Warn that weekly CI fails
runs-on: ubuntu-latest
needs: [test, lint, check-compiles, check-doc]
needs: [test, lint, check-compiles]
permissions:
issues: write
# Use always() so the job doesn't get canceled if any other jobs fail
# Use always() so the job doesn't get canceled if any other jobs fail
if: ${{ always() && contains(needs.*.result, 'failure') }}
steps:
- name: Create issue
Expand All @@ -94,7 +76,7 @@ jobs:
--jq '.[0].number')
if [[ -n $previous_issue_number ]]; then
gh issue comment $previous_issue_number \
--body "Weekly pipeline still fails: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
--body "Weekly pipeline still fails: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}"
else
gh issue create \
--title "$TITLE" \
Expand All @@ -106,6 +88,6 @@ jobs:
GH_REPO: ${{ github.repository }}
TITLE: Main branch fails to compile on Rust beta.
LABELS: C-Bug,S-Needs-Triage
BODY: |
BODY: |
## Weekly CI run has failed.
[The offending run.](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})
12 changes: 6 additions & 6 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
# Rust build artifacts
/target
crates/*/target
target
crates/**/target
benches/**/target
tools/**/target
**/*.rs.bk
/benches/target
/tools/compile_fail_utils/target

# Cargo
Cargo.lock
.cargo/config
.cargo/config.toml

# IDE files
/.idea
/.vscode
.idea
.vscode
.zed
dxcompiler.dll
dxil.dll
Expand Down
Loading

0 comments on commit c5effe6

Please sign in to comment.