In the process of researching Ultralight test failures for Hive, I discovered that the JSON RPC spec currently advises that the portal_*localContent methods return 0x when no content is found.
However, this did not solve a hive test failure for portal_beaconLocalContent for Ultralight when I updated our code to match this spec. After further research, I discovered that trin and fluffy return an error and not 0x when content is not found. This PR updates the spec to reflect the current implemented state of the clients.
Specifically:
Corrects the portal_*localContent responses to reflect that the clients return an error
Adds a new ContentNotFoundError a specifies that the error code returned should be -32001 for the ContentNotFoundError and the message "content not found" following the current Trin implementation.
Adds a -32002 for the ContentNotFoundErrorWithTrace error type that is returned by the traceRecursiveFindContent method types
In the process of researching Ultralight test failures for Hive, I discovered that the JSON RPC spec currently advises that the
portal_*localContent
methods return0x
when no content is found. However, this did not solve a hive test failure forportal_beaconLocalContent
for Ultralight when I updated our code to match this spec. After further research, I discovered thattrin
andfluffy
return an error and not0x
when content is not found. This PR updates the spec to reflect the current implemented state of the clients.Specifically:
portal_*localContent
responses to reflect that the clients return an errorContentNotFoundError
a specifies that the error code returned should be -32001 for theContentNotFoundError
and the message "content not found" following the current Trin implementation.ContentNotFoundErrorWithTrace
error type that is returned by thetraceRecursiveFindContent
method types