Skip to content
This repository was archived by the owner on Mar 5, 2025. It is now read-only.
This repository was archived by the owner on Mar 5, 2025. It is now read-only.

Sign has invalid types and bug when using context wallet #6075

@mpetrunic

Description

@mpetrunic

Method: https://github.com/web3/web3.js/blob/4.x/packages/web3-eth/src/web3_eth.ts#L1076

Docs indicate that you can only get string or buffer as a return type. But the actual typescript return type is:
image

Bug #1: return type should be explicitly written to depend on passed in format(either string or buffer)

Bug #2: From digging through the code, seems like there is actually a bug in the underlying rpc method wrapper where https://github.com/web3/web3.js/blob/4.x/packages/web3-eth/src/rpc_method_wrappers.ts#LL885C40-L885C40 response is not formatted according to input params.

Expected behavior

consistent return type that depends on submitted params

Actual behavior

Steps to reproduce the behavior

  1. [First step]
  2. [Second step]
  3. [and so on...]

Logs

Environment

Metadata

Metadata

Assignees

Labels

4.x4.0 relatedBugAddressing a bug

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions