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

POC/WIP: feat/1098 - Fetch and store MASP params in background #1114

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

jurevans
Copy link
Collaborator

@jurevans jurevans commented Sep 14, 2024

Relates to #1098 & #1099

See: https://github.com/anoma/masp-mpc/releases/tag/namada-trusted-setup

Namadillo will need to fetch and store MASP params once. This PR is to experiment with fetching these within a service worker and storing these in IndexedDB.

To move this PR out of POC status, we need a smoother development & build integration. Currently, packages cannot be imported into this context (specifically, @namada/storage which is the IndexedDB interface we use). For this branch, I am just using a copied version for now. We will potentially be able to improve the Vite pipeline & dev process for working with SW.

Also, to avoid CORS issues, I've had to proxy while working locally. This is not ideal, but is an issue regardless of whether we request in the App vs SW.

  • MASP params can be downloaded, validated and stored in background once
  • Namadillo can query IndexedDB and provide these to the SDK
  • Namadillo can initiate and react to the SW and be updated of its status
  • Fallback method if SW is unavailable

@jurevans jurevans added the PoC Demo / experiment label Sep 14, 2024
@jurevans jurevans self-assigned this Sep 14, 2024
@jurevans jurevans force-pushed the poc/1098-sw-masp-params branch 7 times, most recently from 1ff533c to 0ca187d Compare September 14, 2024 16:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PoC Demo / experiment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant