diff --git a/.github/workflows/ValidatePullRequest.yml b/.github/workflows/ValidatePullRequest.yml index b5890dee2..e621cabe4 100644 --- a/.github/workflows/ValidatePullRequest.yml +++ b/.github/workflows/ValidatePullRequest.yml @@ -46,9 +46,7 @@ jobs: # Cargo.lock files stale. This job updates them before code-checks runs # `cargo fetch --locked` so that the first CI run succeeds. update-guest-locks: - if: >- - github.event.pull_request.user.login == 'dependabot[bot]' && - github.actor == 'dependabot[bot]' + if: github.event.pull_request.user.login == 'dependabot[bot]' uses: ./.github/workflows/dep_update_guest_locks.yml secrets: inherit diff --git a/.github/workflows/dep_update_guest_locks.yml b/.github/workflows/dep_update_guest_locks.yml index e6c4f2729..ed160c37b 100644 --- a/.github/workflows/dep_update_guest_locks.yml +++ b/.github/workflows/dep_update_guest_locks.yml @@ -16,7 +16,6 @@ env: permissions: contents: read - pull-requests: read defaults: run: @@ -27,28 +26,9 @@ jobs: runs-on: [self-hosted, Linux, X64, "1ES.Pool=hld-kvm-amd"] timeout-minutes: 15 steps: - # Fetch metadata about the Dependabot PR - - name: Dependabot metadata - id: metadata - uses: dependabot/fetch-metadata@v2 - with: - github-token: "${{ secrets.GITHUB_TOKEN }}" - - # Only proceed for cargo ecosystem updates - - name: Check if cargo update - id: check-ecosystem - run: | - if [ "${{ steps.metadata.outputs.package-ecosystem }}" = "cargo" ]; then - echo "is_cargo=true" >> "$GITHUB_OUTPUT" - else - echo "is_cargo=false" >> "$GITHUB_OUTPUT" - echo "Skipping non-cargo dependency update" - fi - # Get GitHub App token for pushing commits back to the PR # Uses the same app as auto-merge-dependabot.yml - name: Get GitHub App token - if: steps.check-ecosystem.outputs.is_cargo == 'true' uses: actions/create-github-app-token@v2 id: get-app-token with: @@ -57,7 +37,6 @@ jobs: permission-contents: write - name: Checkout PR branch - if: steps.check-ecosystem.outputs.is_cargo == 'true' uses: actions/checkout@v6 with: token: ${{ steps.get-app-token.outputs.token }} @@ -66,7 +45,6 @@ jobs: persist-credentials: false - name: Setup Rust toolchain - if: steps.check-ecosystem.outputs.is_cargo == 'true' uses: hyperlight-dev/ci-setup-workflow@v1.8.0 with: rust-toolchain: "1.89" @@ -74,22 +52,18 @@ jobs: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - name: Fix cargo home permissions - if: steps.check-ecosystem.outputs.is_cargo == 'true' run: | sudo chown -R $(id -u):$(id -g) /opt/cargo || true - name: Update simpleguest Cargo.lock - if: steps.check-ecosystem.outputs.is_cargo == 'true' working-directory: src/tests/rust_guests/simpleguest run: cargo fetch - name: Update dummyguest Cargo.lock - if: steps.check-ecosystem.outputs.is_cargo == 'true' working-directory: src/tests/rust_guests/dummyguest run: cargo fetch - name: Update witguest Cargo.lock - if: steps.check-ecosystem.outputs.is_cargo == 'true' working-directory: src/tests/rust_guests/witguest run: cargo fetch @@ -105,11 +79,10 @@ jobs: # - Git Data API (Create a commit): # https://docs.github.com/en/rest/git/commits#create-a-commit - name: Commit and push changes via API - if: steps.check-ecosystem.outputs.is_cargo == 'true' env: GH_TOKEN: ${{ steps.get-app-token.outputs.token }} APP_SLUG: ${{ steps.get-app-token.outputs.app-slug }} - DEPENDENCY_NAMES: ${{ steps.metadata.outputs.dependency-names }} + PR_TITLE: ${{ github.event.pull_request.title }} BRANCH: ${{ github.head_ref }} REPO: ${{ github.repository }} run: | @@ -157,7 +130,7 @@ jobs: COMMIT_MSG=$(printf '%s\n\n%s\n%s\n\n%s' \ "chore: update guest Cargo.lock files" \ "Automatically updated by dependabot-update-guest-locks workflow." \ - "Triggered by: ${DEPENDENCY_NAMES}" \ + "Triggered by: ${PR_TITLE}" \ "Signed-off-by: ${SIGNOFF}") # Create commit via API — GitHub signs it automatically since we diff --git a/Cargo.lock b/Cargo.lock index 962fc4a6d..a45712089 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1284,7 +1284,6 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1" dependencies = [ "foldhash 0.1.5", - "serde", ] [[package]] @@ -1294,6 +1293,8 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" dependencies = [ "foldhash 0.2.0", + "serde", + "serde_core", ] [[package]] @@ -1429,7 +1430,7 @@ dependencies = [ "proc-macro2", "quote", "syn", - "wasmparser", + "wasmparser 0.245.1", ] [[package]] @@ -1442,7 +1443,7 @@ dependencies = [ "quote", "syn", "tracing", - "wasmparser", + "wasmparser 0.245.1", ] [[package]] @@ -4087,7 +4088,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "990065f2fe63003fe337b932cfb5e3b80e0b4d0f5ff650e6985b1048f62c8319" dependencies = [ "leb128fmt", - "wasmparser", + "wasmparser 0.244.0", ] [[package]] @@ -4099,7 +4100,7 @@ dependencies = [ "anyhow", "indexmap", "wasm-encoder", - "wasmparser", + "wasmparser 0.244.0", ] [[package]] @@ -4112,6 +4113,18 @@ dependencies = [ "hashbrown 0.15.5", "indexmap", "semver", +] + +[[package]] +name = "wasmparser" +version = "0.245.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4f08c9adee0428b7bddf3890fc27e015ac4b761cc608c822667102b8bfd6995e" +dependencies = [ + "bitflags 2.11.0", + "hashbrown 0.16.1", + "indexmap", + "semver", "serde", ] @@ -4452,7 +4465,7 @@ dependencies = [ "serde_json", "wasm-encoder", "wasm-metadata", - "wasmparser", + "wasmparser 0.244.0", "wit-parser", ] @@ -4471,7 +4484,7 @@ dependencies = [ "serde_derive", "serde_json", "unicode-xid", - "wasmparser", + "wasmparser 0.244.0", ] [[package]] diff --git a/src/hyperlight_component_macro/Cargo.toml b/src/hyperlight_component_macro/Cargo.toml index f3b28c811..e215da645 100644 --- a/src/hyperlight_component_macro/Cargo.toml +++ b/src/hyperlight_component_macro/Cargo.toml @@ -16,7 +16,7 @@ name = "hyperlight_component_macro" proc-macro = true [dependencies] -wasmparser = { version = "0.244.0" } +wasmparser = { version = "0.245.1" } quote = { version = "1.0.44" } proc-macro2 = { version = "1.0.106" } syn = { version = "2.0.117" } diff --git a/src/hyperlight_component_util/Cargo.toml b/src/hyperlight_component_util/Cargo.toml index 4ce0015dd..6e05fcd73 100644 --- a/src/hyperlight_component_util/Cargo.toml +++ b/src/hyperlight_component_util/Cargo.toml @@ -15,7 +15,7 @@ Shared implementation for the procedural macros that generate Hyperlight host an name = "hyperlight_component_util" [dependencies] -wasmparser = { version = "0.244.0" } +wasmparser = { version = "0.245.1" } quote = { version = "1.0.44" } proc-macro2 = { version = "1.0.106" } syn = { version = "2.0.117" } diff --git a/src/hyperlight_component_util/src/elaborate.rs b/src/hyperlight_component_util/src/elaborate.rs index 29120a5ce..1fe7e232f 100644 --- a/src/hyperlight_component_util/src/elaborate.rs +++ b/src/hyperlight_component_util/src/elaborate.rs @@ -402,7 +402,6 @@ impl<'p, 'a> Ctx<'p, 'a> { Ok(VariantCase { name: Name { name: vc.name }, ty: vc.ty.as_ref().map(|ty| self.elab_value(ty)).transpose()?, - refines: vc.refines, }) }) .collect::, Error<'a>>>()?; @@ -433,7 +432,7 @@ impl<'p, 'a> Ctx<'p, 'a> { Defined::Handleable(h) => Ok(Value::Borrow(h.clone())), _ => Err(Error::HandleToNonResource), }, - ComponentDefinedType::FixedSizeList(vt, size) => { + ComponentDefinedType::FixedLengthList(vt, size) => { Ok(Value::FixList(Box::new(self.elab_value(vt)?), *size)) } ComponentDefinedType::Future(_) | ComponentDefinedType::Stream(_) => { diff --git a/src/hyperlight_component_util/src/etypes.rs b/src/hyperlight_component_util/src/etypes.rs index 5723eaf9a..84beb4dae 100644 --- a/src/hyperlight_component_util/src/etypes.rs +++ b/src/hyperlight_component_util/src/etypes.rs @@ -70,7 +70,6 @@ pub struct RecordField<'a> { pub struct VariantCase<'a> { pub name: Name<'a>, pub ty: Option>, - pub refines: Option, } /// valtype_e in the specification diff --git a/src/hyperlight_component_util/src/substitute.rs b/src/hyperlight_component_util/src/substitute.rs index 5ea07d609..5119f3dae 100644 --- a/src/hyperlight_component_util/src/substitute.rs +++ b/src/hyperlight_component_util/src/substitute.rs @@ -77,7 +77,6 @@ where Ok(VariantCase { name: vc.name, ty: self.value_option(&vc.ty)?, - refines: vc.refines, }) }) .collect() diff --git a/src/hyperlight_component_util/src/wf.rs b/src/hyperlight_component_util/src/wf.rs index 20321d6d7..dbede532f 100644 --- a/src/hyperlight_component_util/src/wf.rs +++ b/src/hyperlight_component_util/src/wf.rs @@ -117,13 +117,6 @@ pub enum Error<'a> { DuplicateRecordField(Name<'a>), /// A variant has multiple cases with the same name DuplicateVariantField(Name<'a>), - /// A variant case is marked as refining another case, but that - /// case does not exist - NonexistentVariantRefinement(u32), - /// A variant case is marked as refining another case, but its - /// associated value is not a subtype of the value of the refined - /// case - IncompatibleVariantRefinement(subtype::Error<'a>), /// A flags has multiple flags with the same name DuplicateFlagsName(Name<'a>), /// An enum has multiple cases with the same name @@ -181,15 +174,6 @@ impl<'p, 'a> Ctx<'p, 'a> { |&vc| vc.name.name, |vc| Error::DuplicateVariantField(vc.name), )?; - for vc in vcs { - if let Some(ri) = vc.refines { - let rvc = vcs - .get(ri as usize) - .ok_or(Error::NonexistentVariantRefinement(ri))?; - self.subtype_value_option(&vc.ty, &rvc.ty) - .map_err(Error::IncompatibleVariantRefinement)?; - } - } Ok(()) } fn wf_value<'r>(&'r self, p: ValueTypePosition, vt: &'r Value<'a>) -> Result<(), Error<'a>> { diff --git a/src/tests/rust_guests/witguest/Cargo.lock b/src/tests/rust_guests/witguest/Cargo.lock index bb1dec4a8..fc851cb39 100644 --- a/src/tests/rust_guests/witguest/Cargo.lock +++ b/src/tests/rust_guests/witguest/Cargo.lock @@ -157,9 +157,9 @@ dependencies = [ [[package]] name = "foldhash" -version = "0.1.5" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9c4f5dac5e15c24eb999c26181a6ca40b39fe946cbe4c263c7209467bc83af2" +checksum = "77ce24cb58228fbb8aa041425bb1050850ac19177686ea6e0f41a70416f56fdb" [[package]] name = "glob" @@ -169,20 +169,15 @@ checksum = "0cc23270f6e1808e30a928bdc84dea0b9b4136a8bc82338574f23baf47bbd280" [[package]] name = "hashbrown" -version = "0.15.5" +version = "0.16.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9229cfe53dfd69f0609a49f65461bd93001ea1ef889cd5529dd176593f5338a1" +checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" dependencies = [ "foldhash", "serde", + "serde_core", ] -[[package]] -name = "hashbrown" -version = "0.16.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "841d1cc9bed7f9236f321df977030373f4a4163ae1a7dbfe1a51a2c1a51d9100" - [[package]] name = "hyperlight-common" version = "0.12.0" @@ -274,12 +269,12 @@ dependencies = [ [[package]] name = "indexmap" -version = "2.12.1" +version = "2.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0ad4bb2b565bca0645f4d68c5c9af97fba094e9791da685bf83cb5f3ce74acf2" +checksum = "7714e70437a7dc3ac8eb7e6f8df75fd8eb422675fc7678aff7364301092b1017" dependencies = [ "equivalent", - "hashbrown 0.16.1", + "hashbrown", "serde", "serde_core", ] @@ -654,12 +649,12 @@ checksum = "06abde3611657adf66d383f00b093d7faecc7fa57071cce2578660c9f1010821" [[package]] name = "wasmparser" -version = "0.244.0" +version = "0.245.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47b807c72e1bac69382b3a6fb3dbe8ea4c0ed87ff5629b8685ae6b9a611028fe" +checksum = "4f08c9adee0428b7bddf3890fc27e015ac4b761cc608c822667102b8bfd6995e" dependencies = [ "bitflags", - "hashbrown 0.15.5", + "hashbrown", "indexmap", "semver", "serde", @@ -769,4 +764,4 @@ dependencies = [ name = "zmij" version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0f4a4e8e9dc5c62d159f04fcdbe07f4c3fb710415aab4754bf11505501e3251d" +checksum = "0f4a4e8e9dc5c62d159f04fcdbe07f4c3fb710415aab4754bf11505501e3251d" \ No newline at end of file