Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
persist-credentials: false

- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@fcf085fcb4b4b8f63f96906cd713eb52181b5ea4 # stable
run: rustup show

- name: Rust cache
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2
Expand Down
6 changes: 2 additions & 4 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
persist-credentials: false

- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@22a6a5b0f9f487c5f5587025ae9d4a1caf2a8a78 # clippy
run: rustup show

- name: Rust cache
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2
Expand All @@ -50,9 +50,7 @@ jobs:
persist-credentials: false

- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@fcf085fcb4b4b8f63f96906cd713eb52181b5ea4 # stable
with:
components: rustfmt
run: rustup show

- name: Check Rust formatting
run: cargo fmt --all --check
Expand Down
21 changes: 1 addition & 20 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,4 @@ jobs:
persist-credentials: false

- name: Upload binary to release
uses: ncipollo/release-action@339a81892b84b4eeb0f6e744e4574d79d0d9b8dd # v1

# cratesio:
# name: Publish Release to Crates.io
# runs-on: ubuntu-latest
# permissions:
# contents: read
# steps:
# - name: Checkout repository
# uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v4
# with:
# persist-credentials: false

# - name: Install Rust toolchain
# uses: dtolnay/rust-toolchain@fcf085fcb4b4b8f63f96906cd713eb52181b5ea4 # stable

# - name: Publish to crates.io
# run: cargo publish
# env:
# CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
run: gh release
2 changes: 1 addition & 1 deletion .github/workflows/security.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
persist-credentials: false

- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@22a6a5b0f9f487c5f5587025ae9d4a1caf2a8a78 # clippy
run: rustup show

- name: Rust cache
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/unit.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ jobs:
persist-credentials: false

- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@fcf085fcb4b4b8f63f96906cd713eb52181b5ea4 # stable
run: rustup show

- name: Install latest cargo-nextest release
uses: taiki-e/install-action@3216b6964cbfe053bb8b9a2ef245bd9300e2061d # v2.62.14
Expand Down Expand Up @@ -62,7 +62,7 @@ jobs:
persist-credentials: false

- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@fcf085fcb4b4b8f63f96906cd713eb52181b5ea4 # stable
run: rustup show

- name: Rust cache
uses: Swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 # v2
Expand Down
16 changes: 8 additions & 8 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ members = [
resolver = "2"

[workspace.package]
version = "0.14.0"
version = "0.15.0"
edition = "2024"
authors = [
"Trey Del Bonis <trey@alpenlabs.io>",
Expand Down
7 changes: 5 additions & 2 deletions crates/ssz_codegen/src/types/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2275,7 +2275,10 @@ impl ClassDef {
let inner = &**ty;
if matches!(inner.resolution, TypeResolutionKind::UInt(8)) {
quote! {
#field_name: self.#field_name().expect("valid view").to_owned().into()
#field_name: ssz_types::VariableList::new(
self.#field_name().expect("valid view").to_owned(),
)
.expect("valid view")
}
} else {
quote! {
Expand All @@ -2288,7 +2291,7 @@ impl ClassDef {
})
.collect();
let items = items.expect("valid view");
ssz_types::VariableList::from(items)
ssz_types::VariableList::new(items).expect("valid view")
}
}
}
Expand Down
7 changes: 5 additions & 2 deletions crates/ssz_codegen/tests/expected_output/test_1.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1488,7 +1488,10 @@ pub mod tests {
)]
pub fn to_owned(&self) -> Beta {
Beta {
d: self.d().expect("valid view").to_owned().into(),
d: ssz_types::VariableList::new(
self.d().expect("valid view").to_owned(),
)
.expect("valid view"),
e: self.e().expect("valid view"),
f: self.f().expect("valid view"),
}
Expand Down Expand Up @@ -2689,7 +2692,7 @@ pub mod tests {
})
.collect();
let items = items.expect("valid view");
ssz_types::VariableList::from(items)
ssz_types::VariableList::new(items).expect("valid view")
},
large_int_128: self.large_int_128().expect("valid view"),
large_int_256: self.large_int_256().expect("valid view"),
Expand Down
Loading
Loading