Skip to content

Standardise all errors thrown in execution environments#1830

Merged
Mrtenz merged 8 commits intomainfrom
mrtenz/standardise-executor-errors
Oct 9, 2023
Merged

Standardise all errors thrown in execution environments#1830
Mrtenz merged 8 commits intomainfrom
mrtenz/standardise-executor-errors

Conversation

@Mrtenz
Copy link
Copy Markdown
Member

@Mrtenz Mrtenz commented Oct 9, 2023

This replaces all errors thrown in snaps-execution-environments with a JSON-RPC error using eth-rpc-errors.

Fixes #1823

@Mrtenz Mrtenz requested a review from a team as a code owner October 9, 2023 10:15
…tor.ts

Co-authored-by: Frederik Bolding <frederik.bolding@gmail.com>
@Mrtenz
Copy link
Copy Markdown
Member Author

Mrtenz commented Oct 9, 2023

@metamaskbot update-pr

FrederikBolding
FrederikBolding previously approved these changes Oct 9, 2023
@codecov
Copy link
Copy Markdown

codecov bot commented Oct 9, 2023

Codecov Report

Attention: 4 lines in your changes are missing coverage. Please review.

Comparison is base (fbf605d) 95.97% compared to head (7b27b2b) 95.97%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1830   +/-   ##
=======================================
  Coverage   95.97%   95.97%           
=======================================
  Files         241      241           
  Lines        5591     5596    +5     
  Branches      881      881           
=======================================
+ Hits         5366     5371    +5     
  Misses        225      225           
Files Coverage Δ
...cution-environments/src/common/endowments/index.ts 100.00% <100.00%> (ø)
...ion-environments/src/common/endowments/interval.ts 100.00% <100.00%> (ø)
...tion-environments/src/common/endowments/timeout.ts 100.00% <100.00%> (ø)
...-execution-environments/src/common/globalEvents.ts 100.00% <100.00%> (ø)
...-execution-environments/src/common/globalObject.ts 100.00% <ø> (ø)
...s/snaps-execution-environments/src/common/utils.ts 93.75% <100.00%> (ø)
...ps-execution-environments/src/common/validation.ts 100.00% <100.00%> (ø)
...cution-environments/src/common/BaseSnapExecutor.ts 90.34% <20.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Mrtenz Mrtenz merged commit 4fca3bd into main Oct 9, 2023
@Mrtenz Mrtenz deleted the mrtenz/standardise-executor-errors branch October 9, 2023 11:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Standardise errors thrown from Snap executors

3 participants