ethereum / execution-apis

Collection of APIs provided by Ethereum execution layer clients
Creative Commons Zero v1.0 Universal
908 stars 352 forks source link

remove unevaluatedProperties #537

Open shanejonas opened 2 months ago

shanejonas commented 2 months ago

getting this error when using this JSON Schema and ajv.

unevaluatedProperties is part of JSON Schema 2019, we shouldn't use it anyways in an OpenRPC document since the spec points out using JSON Schema 07.

strict mode: unknown keyword: "unevaluatedProperties"

are we sure we need unevaluatedProperties here?

lightclient commented 2 months ago

The original discussion is here: https://github.com/ethereum/execution-apis/pull/435#discussion_r1258656701

I also noted that it was not available in draft 07, but didn't realize that was a strict requirement for OpenRPC. Seems like we should remove it, but it appears there is an issue with schema if we directly accept this PR:

https://www.jsonschemavalidator.net/s/pGB6o5eO

Any idea how to keep the schema strict here, but still remove this value?

shanejonas commented 2 months ago

if I remove the stuff inline with oneOf the gas, gasPrice etc passes validation. Maybe something up with the merge-all-of?

image