Skip to content

feat: Add onAssetHistoricalPrice handler#3282

Merged
GuillaumeRx merged 10 commits intomainfrom
gr/on-asset-historical-price
Apr 3, 2025
Merged

feat: Add onAssetHistoricalPrice handler#3282
GuillaumeRx merged 10 commits intomainfrom
gr/on-asset-historical-price

Conversation

@GuillaumeRx
Copy link
Copy Markdown
Contributor

@GuillaumeRx GuillaumeRx commented Mar 31, 2025

This PR adds a new handler called onAssetHistoricalPrice.

Small updates bundled in this PR:

  • Create a util function assertRequestArguments in the execution-environment validation to remove code duplication.

Progresses: #3229

Comment thread packages/snaps-utils/src/asset-historical-price.ts
Comment thread packages/snaps-utils/src/structs.ts Outdated
Comment thread packages/snaps-rpc-methods/src/permitted/scheduleBackgroundEvent.ts Outdated
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 1, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.88%. Comparing base (48f76da) to head (322f804).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3282   +/-   ##
=======================================
  Coverage   94.87%   94.88%           
=======================================
  Files         517      518    +1     
  Lines       11336    11357   +21     
  Branches     1750     1752    +2     
=======================================
+ Hits        10755    10776   +21     
  Misses        581      581           

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

github-merge-queue Bot pushed a commit that referenced this pull request Apr 1, 2025
This PR moves 2 refiners related to ISO 8601 time strings to
`snaps-utils`, this allows the refiner to be used in other places
(required for #3282).
@GuillaumeRx GuillaumeRx force-pushed the gr/on-asset-historical-price branch from a74acb4 to 4238235 Compare April 2, 2025 12:48
Comment thread packages/snaps-sdk/src/types/handlers/asset-historical-price.ts Outdated
Comment thread packages/snaps-execution-environments/src/common/validation.ts Outdated
Comment thread packages/snaps-utils/src/handlers/types.ts
Comment thread packages/snaps-execution-environments/lavamoat/browserify/worker-pool/policy.json Outdated
@GuillaumeRx GuillaumeRx force-pushed the gr/on-asset-historical-price branch from b357b29 to 1063f83 Compare April 2, 2025 13:52
@GuillaumeRx GuillaumeRx force-pushed the gr/on-asset-historical-price branch from d75399f to 40c42d8 Compare April 3, 2025 09:37
@GuillaumeRx GuillaumeRx marked this pull request as ready for review April 3, 2025 09:37
@GuillaumeRx GuillaumeRx requested a review from a team as a code owner April 3, 2025 09:37
@GuillaumeRx GuillaumeRx enabled auto-merge April 3, 2025 09:41
@GuillaumeRx GuillaumeRx added this pull request to the merge queue Apr 3, 2025
Merged via the queue into main with commit 8e418f6 Apr 3, 2025
172 checks passed
@GuillaumeRx GuillaumeRx deleted the gr/on-asset-historical-price branch April 3, 2025 10:09
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.

2 participants