Skip to content

SortedMap signature mismatch from Map #617

@linuxninja39

Description

@linuxninja39

I’ve done a fresh install of helia, I’m on typescript 4.9.5 and node 21.4.0. When trying to compile my project I’m getting the following error.

Error: node_modules/ipfs-bitswap/dist/src/utils/sorted-map.d.ts:24:5 - error TS2416: Property ‘forEach’ in type ‘SortedMap<Key, Value>’ is not assignable to the same property in base type ‘Map<Key, Value>’.
Type ‘(cb: (entry: [Key, Value]) => void, thisArg?: SortedMap<Key, Value> | undefined) => void’ is not assignable to type ‘(callbackfn: (value: Value, key: Key, map: Map<Key, Value>) => void, thisArg?: any) => void’.
Types of parameters ‘cb’ and ‘callbackfn’ are incompatible.

This is happening with both ipfs-bitswap 19 and 20.

Metadata

Metadata

Assignees

No one assigned

    Labels

    need/triageNeeds initial labeling and prioritization

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions