Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bump snaps packages #21255

Merged
merged 7 commits into from
Oct 10, 2023
Merged

Bump snaps packages #21255

merged 7 commits into from
Oct 10, 2023

Conversation

FrederikBolding
Copy link
Member

@FrederikBolding FrederikBolding commented Oct 9, 2023

Description

Bump snaps packages to latest.

This release adds some under the hood support for a new keyring export. It also adds support for showing SVGs in snaps custom UI.

As part of bumping the packages we had to update TypeScript as well. We had a long-standing patch to TypeScript that could be easily replaced with a small patch to LavaMoat to enable overrideTaming. This feature is also set to be enabled in the next version of LavaMoat.

@FrederikBolding FrederikBolding added the team-snaps DEPRECATED: Use "team-snaps-platform" or "team-snaps-ecosystem" instead label Oct 9, 2023
@FrederikBolding FrederikBolding requested review from a team as code owners October 9, 2023 09:45
@socket-security
Copy link

socket-security bot commented Oct 9, 2023

New and updated dependencies detected. Learn more about Socket for GitHub ↗︎

Packages Version New capabilities Transitives Size Publisher
@metamask/snaps-ui 3.0.0 None +0 63.5 kB
@metamask/rpc-methods 3.0.0 None +2 1.2 MB
@metamask/snaps-controllers 3.0.0 None +4 7.4 MB
@metamask/snaps-utils 3.0.0 None +1 718 kB metamaskbot
typescript 4.4.4...4.5.5 None +0/-0 64 MB typescript-bot

@socket-security
Copy link

socket-security bot commented Oct 9, 2023

👍 Dependency issues cleared. Learn more about Socket for GitHub ↗︎

This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored.

Ignoring: @metamask/[email protected], @metamask/[email protected], @metamask/[email protected], @metamask/[email protected]

Next steps

Take a deeper look at the dependency

Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support [AT] socket [DOT] dev.

Remove the package

If you happen to install a dependency that Socket reports as Known Malware you should immediately remove it and select a different dependency. For other alert types, you may may wish to investigate alternative packages or consider if there are other ways to mitigate the specific risk posed by the dependency.

Mark a package as acceptable risk

To ignore an alert, reply with a comment starting with @SocketSecurity ignore followed by a space separated list of package-name@version specifiers. e.g. @SocketSecurity ignore [email protected] bar@* or ignore all packages with @SocketSecurity ignore-all

@metamaskbot
Copy link
Collaborator

Builds ready [a499bb1]
Page Load Metrics (897 ± 468 ms)
PlatformPageMetricMin (ms)Max (ms)Average (ms)StandardDeviation (ms)MarginOfError (ms)
ChromeHomefirstPaint861801162110
domContentLoaded681461022211
load802363897975468
domInteractive681461022211
Bundle size diffs [🚨 Warning! Bundle size has increased!]
  • background: 549 Bytes (0.01%)
  • ui: 1.38 KiB (0.02%)
  • common: 22.15 KiB (0.46%)

@codecov
Copy link

codecov bot commented Oct 9, 2023

Codecov Report

All modified lines are covered by tests ✅

Comparison is base (5236e02) 68.64% compared to head (a499bb1) 68.64%.
Report is 3 commits behind head on develop.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop   #21255   +/-   ##
========================================
  Coverage    68.64%   68.64%           
========================================
  Files         1017     1017           
  Lines        40797    40797           
  Branches     10893    10893           
========================================
  Hits         28004    28004           
  Misses       12793    12793           
Files Coverage Δ
shared/constants/snaps/permissions.ts 100.00% <ø> (ø)
.../metamask-template-renderer/safe-component-list.js 100.00% <ø> (ø)

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

@FrederikBolding
Copy link
Member Author

@SocketSecurity ignore @metamask/[email protected]
@SocketSecurity ignore @metamask/[email protected]
@SocketSecurity ignore @metamask/[email protected]
@SocketSecurity ignore @metamask/[email protected]

We own these and they are published, not sure why Socket can't find them.

@@ -4791,6 +4808,34 @@ __metadata:
languageName: node
linkType: hard

"@metamask/snaps-controllers@npm:^3.0.0":
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it expected and accepted that we now use two different instances of snaps-controllers and thereby two distinct versions of snaps-execution-environment?

Old version is still used through @metamask/keyring-api and @metamask/eth-snap-keyring.

Copy link
Contributor

@danroc danroc Oct 10, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In the keyring-api, it was updated on version 1.0.0-rc.1 (pending approval to publish), and once it's released, I'll update the eth-snap-keyring too.

This should be part of #21246, which is stacked over this PR.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, this should be fine. snaps-controllers should only be used for types in keyring-api etc, it shouldn't be a problem. snaps-execution-environment isn't directly in use by the extension at all, as it uses the iframe hosted externally.

@FrederikBolding FrederikBolding merged commit 421b598 into develop Oct 10, 2023
@FrederikBolding FrederikBolding deleted the fb/bump-snaps-pkgs branch October 10, 2023 08:51
@github-actions github-actions bot locked and limited conversation to collaborators Oct 10, 2023
@metamaskbot metamaskbot added the release-11.4.0 Issue or pull request that will be included in release 11.4.0 label Oct 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
release-11.4.0 Issue or pull request that will be included in release 11.4.0 team-snaps DEPRECATED: Use "team-snaps-platform" or "team-snaps-ecosystem" instead
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants