Skip to content
This repository was archived by the owner on Jan 2, 2026. It is now read-only.

Commit 53235dc

Browse files
authored
Release v0.20.0 🎉 (#617)
Release tracker for v0.20.0 of chorus, set to release on the 15th of May 2025 Major changes in this version include: - An overhaul of how errors are handled and error cases, including JSON error support (#607) - A new API for ignoring users + updates to the `Relationship` struct (#606) - Several internal changes and fixes ## Public API changes - changes to `ChorusError`: - `ReceivedErrorCode` is now `ReceivedError`, which contains a more specific error object - `InvalidFormBody` has been removed - `InvalidResponse` now contains the response's HTTP status - due to the ratelimiter changes, `Instance` methods that send API requests now need an `&mut self` reference - to avoid cloning `Instance`s, auth routes (login, register and mfa) now take a cloned `Shared<Instance>`. The best practice way to handle `Instance`s is now to call `into_shared()`, store `Shared<Instance>` instead of `Instance` and call `.clone()` on the `Arc` when creating new `ChorusUser`s - new fields in the `Relationship` struct: - `is_spam_request`, - `stranger_request`, - `origin_application_id` and - `user_ignored` ## Additions - `ChorusUser::bulk_remove_relationships` - `ChorusUser::ignore_user` - `ChorusUser::unignore_user` - JSON Error and Api error types ## Bugfixes - #616 - `Instance`s are no longer cloned when logging into or registering accounts ## Internal changes - #607 (refactoring the internal ratelimiter and request logic, making it support requests without a `ChorusUser`) - #608 by @zicklag (updating internal self-updating struct logic, removing an unsafe block for safer code) - #612 and #613 by @bitfl0wer (improving CI, more checks for security) - #614 (updating the url of discord userdoccers links in documentation) - several dependency bumps
2 parents 8483470 + 481d7d0 commit 53235dc

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

100 files changed

+2754
-1803
lines changed
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Build and Test
1+
name: "Rust: Build, Test, Publish Coverage"
22

33
on:
44
push:
@@ -108,7 +108,7 @@ jobs:
108108
run: |
109109
rustup target add wasm32-unknown-unknown
110110
curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
111-
cargo binstall --no-confirm wasm-bindgen-cli --version "0.2.95" --force
111+
cargo binstall --no-confirm wasm-bindgen-cli --version "0.2.100" --force
112112
GECKODRIVER=$(which geckodriver) cargo test --target wasm32-unknown-unknown --no-default-features --features="client, rt, voice_gateway"
113113
wasm-chrome:
114114
runs-on: ubuntu-latest
@@ -144,5 +144,5 @@ jobs:
144144
run: |
145145
rustup target add wasm32-unknown-unknown
146146
curl -L --proto '=https' --tlsv1.2 -sSf https://raw.githubusercontent.com/cargo-bins/cargo-binstall/main/install-from-binstall-release.sh | bash
147-
cargo binstall --no-confirm wasm-bindgen-cli --version "0.2.95" --force
147+
cargo binstall --no-confirm wasm-bindgen-cli --version "0.2.100" --force
148148
CHROMEDRIVER=$(which chromedriver) cargo test --target wasm32-unknown-unknown --no-default-features --features="client, rt, voice_gateway"

.github/workflows/cargo-doc.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@ name: cargo doc lints
22

33
on:
44
push:
5-
branches: [ "main", "preserve/*" ]
5+
branches: ["main", "preserve/*"]
66
pull_request:
7-
branches: [ "main", "dev" ]
7+
branches: ["main", "dev"]
88

99
jobs:
1010
cargo-doc-lints:

.github/workflows/license-header.yml

Lines changed: 0 additions & 17 deletions
This file was deleted.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: "General: License headers and identifiers"
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
tags: ["*"]
7+
pull_request:
8+
branches: ["*"]
9+
workflow_dispatch:
10+
11+
jobs:
12+
license-headers:
13+
runs-on: ubuntu-latest
14+
timeout-minutes: 10
15+
steps:
16+
- name: Checkout code
17+
uses: actions/checkout@v4
18+
- name: Check license headers
19+
uses: viperproject/check-license-header@e06c65614fa9f32e099838df4dd25440c5344b32
20+
with:
21+
path: .
22+
config: ./.github/license-check/config.json
23+
strict: true

.github/workflows/rust-clippy.yml

Lines changed: 0 additions & 50 deletions
This file was deleted.
Lines changed: 67 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,67 @@
1+
name: "Rust: Compliance"
2+
3+
on:
4+
push:
5+
branches: ["main"]
6+
tags: ["*"]
7+
pull_request:
8+
branches: ["*"]
9+
10+
env:
11+
CARGO_TERM_COLOR: always
12+
13+
jobs:
14+
rust-clippy-analyze:
15+
name: Run rust-clippy analyzing
16+
runs-on: ubuntu-latest
17+
permissions:
18+
contents: read
19+
security-events: write
20+
actions: read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status
21+
steps:
22+
- name: Checkout code
23+
uses: actions/checkout@v4
24+
25+
- name: Install Rust toolchain
26+
uses: dtolnay/rust-toolchain@stable
27+
with:
28+
components: clippy
29+
30+
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6
31+
32+
- name: Install cargo-binstall
33+
uses: taiki-e/install-action@7cb2cdb5024b2b45585f150af1ee02e24b87edd7
34+
with:
35+
tool: cargo-binstall
36+
37+
- name: Install additionally required components
38+
run: cargo binstall cargo-udeps clippy-sarif sarif-fmt cargo-deny --only-signed --force -y
39+
40+
- name: Run rust-clippy
41+
run: cargo clippy
42+
--all-features
43+
--message-format=json | clippy-sarif | tee rust-clippy-results.sarif | sarif-fmt
44+
continue-on-error: true
45+
46+
- name: Upload clippy analysis results to GitHub
47+
uses: github/codeql-action/upload-sarif@v3
48+
with:
49+
sarif_file: rust-clippy-results.sarif
50+
wait-for-processing: true
51+
52+
- name: Analyze crate dependency licenses with cargo-deny
53+
uses: EmbarkStudios/cargo-deny-action@34899fc7ba81ca6268d5947a7a16b4649013fea1
54+
with:
55+
command: check licenses
56+
57+
- name: Install Rust nightly toolchain
58+
uses: dtolnay/rust-toolchain@master
59+
with:
60+
components: clippy
61+
toolchain: nightly
62+
63+
- name: Activate nightly Rust toolchain
64+
run: rustup default nightly
65+
66+
- name: cargo-udeps
67+
run: cargo +nightly udeps --all-targets --all-features
Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: "Rust: Security: Automated dependency analysis"
2+
3+
on:
4+
push:
5+
branches: ["main", "preserve/*"]
6+
pull_request:
7+
# The branches below must be a subset of the branches above
8+
branches: ["main", "dev"]
9+
workflow_dispatch:
10+
schedule:
11+
- cron: "0 7 * * 1"
12+
13+
jobs:
14+
cargo-deny:
15+
runs-on: ubuntu-latest
16+
timeout-minutes: 10
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@v4
20+
- name: Install latest, stable Rust toolchain
21+
uses: dtolnay/rust-toolchain@stable
22+
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6
23+
- name: Analyze crate dependencies for advisories with cargo-deny
24+
uses: EmbarkStudios/cargo-deny-action@34899fc7ba81ca6268d5947a7a16b4649013fea1
25+
with:
26+
command: check advisories sources bans
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: "Rust: Semver release checks"
2+
3+
on:
4+
pull_request:
5+
branches: ["main"]
6+
7+
env:
8+
CARGO_TERM_COLOR: always
9+
10+
jobs:
11+
semver-checks:
12+
runs-on: ubuntu-latest
13+
timeout-minutes: 60
14+
15+
steps:
16+
- uses: actions/checkout@v4
17+
- uses: Swatinem/rust-cache@9d47c6ad4b02e050fd481d890b2ea34778fd09d6
18+
- uses: obi1kenobi/cargo-semver-checks-action@7272cc2caa468d3e009a2b0a9cc366839348237b

0 commit comments

Comments
 (0)