Skip to content

Commit

Permalink
feat: update bevy to 0.12 (#3)
Browse files Browse the repository at this point in the history
1. Update Bevy to 0.12
2. Update related deps ( ggrs, bevy_ggrs, matchbox, etc. )
3. Log warning if winit cannot find main window to avoid panic - I don't
understand why this changed see below.
4. Switch to `1.72` toolchain due to Rust compiler regression.

### Winit Panic

Some new issue was introduced with the Bevy 0.12 upgrade, this line
started panicking, so we just log a warning and abort if we can't get
the primary window.


https://github.com/mikeder/turtletime/pull/3/files#diff-42cb6807ad74b3e201c5a7ca98b911c5fa08380e942be6e4ac5807f8377f87fcL83

NiklasEi/bevy_game_template#80

### Compiler Regression

I was unable to compile `bevy-egui-inspector` after updating to Rust to
the 1.74 toolchain, it turns out there was a compiler regression so I've
pinned my toolchain to 1.72 ( there was [another
regression](rust-lang/rust#117545) in 1.73
that sounds nasty enough to avoid for now too )

jakobhellermann/bevy-inspector-egui#163
rust-lang/rust#117976

#### Segmentation Fault

Originally I tried to use the `nightly` toolchain as recommended in the
above `bevy-egui-inspector` issue, but when I did, my game instantly
crashed with a segmentation fault. I tried to use the
[sanitizer](https://doc.rust-lang.org/beta/unstable-book/compiler-flags/sanitizer.html)
features to debug it, but the game compiled and ran just fine with the
sanitizer flags. Ultimately I just downgraded to `1.72` and moved on
with my life.
  • Loading branch information
mikeder authored Nov 19, 2023
1 parent 20234db commit 8f0e974
Show file tree
Hide file tree
Showing 13 changed files with 837 additions and 903 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
key: ${{ runner.os }}-cargo-build-stable-${{ hashFiles('**/Cargo.toml') }}
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
override: true
- name: Install alsa and udev
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
Expand All @@ -45,7 +45,7 @@ jobs:
key: ubuntu-latest-cargo-build-stable-${{ hashFiles('**/Cargo.toml') }}
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
override: true
- name: Install alsa and udev
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
Expand All @@ -66,7 +66,7 @@ jobs:
key: ubuntu-latest-cargo-build-stable-${{ hashFiles('**/Cargo.toml') }}
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
components: rustfmt, clippy
override: true
- name: Install alsa and udev
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/deploy-page.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Install rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
override: true
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install pkg-config libx11-dev libasound2-dev libudev-dev
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ jobs:
- name: Install rust toolchain for Apple Silicon
uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
target: aarch64-apple-darwin
override: true
- name: Build release for Apple Silicon
Expand All @@ -56,7 +56,7 @@ jobs:
- name: Install rust toolchain for Apple x86
uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
target: x86_64-apple-darwin
override: true
- name: Build release for x86 Apple
Expand Down Expand Up @@ -95,7 +95,7 @@ jobs:
- name: Install rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
override: true
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install pkg-config libx11-dev libasound2-dev libudev-dev
Expand Down Expand Up @@ -130,7 +130,7 @@ jobs:
- name: Install rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
override: true
- name: Install dotnet
uses: actions/setup-dotnet@v3
Expand Down Expand Up @@ -178,7 +178,7 @@ jobs:
- name: Install rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
toolchain: 1.72
override: true
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install pkg-config libx11-dev libasound2-dev libudev-dev
Expand Down
Loading

0 comments on commit 8f0e974

Please sign in to comment.