-
Notifications
You must be signed in to change notification settings - Fork 11.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' into interfaces/erc/5313
- Loading branch information
Showing
16 changed files
with
553 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'openzeppelin-solidity': minor | ||
--- | ||
|
||
`StorageSlot`: Add support for `string` and `bytes`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
name: Compare storage layouts | ||
inputs: | ||
token: | ||
description: github token | ||
required: true | ||
buildinfo: | ||
description: compilation artifacts | ||
required: false | ||
default: artifacts/build-info/*.json | ||
layout: | ||
description: extracted storage layout | ||
required: false | ||
default: HEAD.layout.json | ||
out_layout: | ||
description: storage layout to upload | ||
required: false | ||
default: ${{ github.ref_name }}.layout.json | ||
ref_layout: | ||
description: storage layout for the reference branch | ||
required: false | ||
default: ${{ github.base_ref }}.layout.json | ||
|
||
runs: | ||
using: composite | ||
steps: | ||
- name: Extract layout | ||
run: | | ||
node scripts/checks/extract-layout.js ${{ inputs.buildinfo }} > ${{ inputs.layout }} | ||
shell: bash | ||
- name: Download reference | ||
if: github.event_name == 'pull_request' | ||
run: | | ||
RUN_ID=`gh run list --repo ${{ github.repository }} --branch ${{ github.base_ref }} --workflow ${{ github.workflow }} --limit 100 --json 'conclusion,databaseId,event' --jq 'map(select(.conclusion=="success" and .event!="pull_request"))[0].databaseId'` | ||
gh run download ${RUN_ID} --repo ${{ github.repository }} -n layout | ||
env: | ||
GITHUB_TOKEN: ${{ inputs.token }} | ||
shell: bash | ||
continue-on-error: true | ||
id: reference | ||
- name: Compare layouts | ||
if: steps.reference.outcome == 'success' && github.event_name == 'pull_request' | ||
run: | | ||
node scripts/checks/compare-layout.js --head ${{ inputs.layout }} --ref ${{ inputs.ref_layout }} >> $GITHUB_STEP_SUMMARY | ||
shell: bash | ||
- name: Rename artifacts for upload | ||
if: github.event_name != 'pull_request' | ||
run: | | ||
mv ${{ inputs.layout }} ${{ inputs.out_layout }} | ||
shell: bash | ||
- name: Save artifacts | ||
if: github.event_name != 'pull_request' | ||
uses: actions/upload-artifact@v3 | ||
with: | ||
name: layout | ||
path: ${{ inputs.out_layout }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.