opensea-js icon indicating copy to clipboard operation
opensea-js copied to clipboard

fulfillOrder failing with TypeError: Cannot read properties of null (reading 'toHexString')

Open nickfujita opened this issue 3 years ago • 2 comments

When calling fulfillOrder, the operation is failing with the following error: TypeError: Cannot read properties of null (reading 'toHexString')

image

v4.0.23 Ethereum & Polygon mainnets

nickfujita avatar Mar 10 '23 04:03 nickfujita

Hey Nick! I assume you interact directly with Seaport js to sign order, so now you need to get fulfillment data from API in a separate call. See how it is done in Seaport js. There you will get signature and function call ABI (which you are missing).

https://github.com/ProjectOpenSea/opensea-js/blob/4ff77166f72a9b08ec76a134c9965f6dfef63c9e/src/sdk.ts#L1115

lukaskai avatar Mar 12 '23 13:03 lukaskai

Thanks @lukaskai looks like we were discarding the orderHash since it wasn't being used previously. Seems to work when using seaport-js directly instead. However, ran into another issue where only the networks from the legacy wyvern Network are available. This causes failures not only when using OpenSeaSDK.fulfillOrder, but even trying to use OpenSeaAPI. generateFulfillmentData fails since it's unable to properly map the networkName for anything other than Ethereum and Goerli

In any case was able to get it working eventually by calling things manually, so closing out this issue 🙏🏼

nickfujita avatar Mar 13 '23 10:03 nickfujita