MetaMask / MetaMask/snaps

Forward console from snap to dapp console

Open
#965 0 comments 1 reaction 0 assignees View on GitHub
Dominant language
TypeScript
Stars
853
Forks
662
Avg merge
2d 8h
Merged PRs (30d)
8

Description

A lot of people are having trouble getting logs from background.html console log.

Since we control the environment, we can catch all `console.logs` in the sandbox and forward it to all dapps talking with that snap into `window.ethereum` provider and do `console.log` there.

That way, developers will see snap errors in their console log of their application.

Context #959

Contributor guide

Open the contributing guide

Research direction

Review the snap sandbox and background.html logging path, then trace how messages reach the window.ethereum provider; context #959 is the only referenced issue. Done means console output from a snap is forwarded to every connected dapp and appears in that dapp's console.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
developer-experience
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.