-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Empty object produces an error when passed as document to oa-verify #111
Comments
Hi, What do you mean by proper validation error? Do you expect us to throw an error with a message like "invalid document" or something else? |
@Nebulis I mean, that it's clearly a validator encountered the situation that it didn't expect, unexpected error, in other words. In this case an empty document. So, I think it will be logical if instead of failing to perform validation and interrupting the whole process it will simply return |
3 verifiers trigger an error when an empty object is passed down:
For all those verifiers the error happens during the test function (which determines if a verifier should run or not) The plan is to fix those test functions so that the verifiers doesn't run if issuers property (in that case) is not provided => the result for those verifiers will be skipped fragment. On top of that OpenAttestationHash verifier currently return invalid while it shouldn't run because targethash/merkleroot/data are missing => the plan is to fix this behaviour so that the verifier is skipped in that case. Also to make sure that verifiers test function handle correctly, we should provide a partial object (deeply) |
closes #111 3 verifiers trigger an error when an empty object is passed down: OpenAttestationEthereumDocumentStoreStatus OpenAttestationDnsTxt OpenAttestationEthereumTokenRegistryStatus For all those verifiers the error happens during the test function (which determines if a verifier should run or not) The plan is to fix those test functions so that the verifiers doesn't run if issuers property (in that case) is not provided => the result for those verifiers will be skipped fragment. On top of that OpenAttestationHash verifier currently return invalid while it shouldn't run because targethash/merkleroot/data are missing => the plan is to fix this behaviour so that the verifier is skipped in that case. Also to make sure that verifiers test function handle correctly, we should provide a partial object (deeply)
3 verifiers trigger an error when an empty object is passed down: - OpenAttestationEthereumDocumentStoreStatus - OpenAttestationDnsTxt - OpenAttestationEthereumTokenRegistryStatus For all those verifiers the error happens during the test function (which determines if a verifier should run or not). The plan is to fix those test functions so that the verifiers doesn't run if issuers property (in that case) is not provided => the result for those verifiers will be skipped fragment. On top of that OpenAttestationHash verifier currently return invalid while it shouldn't run because targethash/merkleroot/data are missing => the plan is to fix this behaviour so that the verifier is skipped in that case. Also to make sure that verifiers test function handle correctly, we should provide a partial object (deeply) closes #111
3 verifiers trigger an error when an empty object is passed down: - OpenAttestationEthereumDocumentStoreStatus - OpenAttestationDnsTxt - OpenAttestationEthereumTokenRegistryStatus For all those verifiers the error happens during the test function (which determines if a verifier should run or not). The plan is to fix those test functions so that the verifiers doesn't run if issuers property (in that case) is not provided => the result for those verifiers will be skipped fragment. On top of that OpenAttestationHash verifier currently return invalid while it shouldn't run because targethash/merkleroot/data are missing => the plan is to fix this behaviour so that the verifier is skipped in that case. Also to make sure that verifiers test function handle correctly, we should provide a partial object (deeply) closes #111
3 verifiers trigger an error when an empty object is passed down: - OpenAttestationEthereumDocumentStoreStatus - OpenAttestationDnsTxt - OpenAttestationEthereumTokenRegistryStatus For all those verifiers the error happens during the test function (which determines if a verifier should run or not). The plan is to fix those test functions so that the verifiers doesn't run if issuers property (in that case) is not provided => the result for those verifiers will be skipped fragment. On top of that OpenAttestationHash verifier currently return invalid while it shouldn't run because targethash/merkleroot/data are missing => the plan is to fix this behaviour so that the verifier is skipped in that case. Also to make sure that verifiers test function handle correctly, we should provide a partial object (deeply) closes #111
3 verifiers trigger an error when an empty object is passed down: - OpenAttestationEthereumDocumentStoreStatus - OpenAttestationDnsTxt - OpenAttestationEthereumTokenRegistryStatus For all those verifiers the error happens during the test function (which determines if a verifier should run or not). The plan is to fix those test functions so that the verifiers doesn't run if issuers property (in that case) is not provided => the result for those verifiers will be skipped fragment. On top of that OpenAttestationHash verifier currently return invalid while it shouldn't run because targethash/merkleroot/data are missing => the plan is to fix this behaviour so that the verifier is skipped in that case. Also to make sure that verifiers test function handle correctly, we should provide a partial object (deeply) closes #111
3 verifiers trigger an error when an empty object is passed down: - OpenAttestationEthereumDocumentStoreStatus - OpenAttestationDnsTxt - OpenAttestationEthereumTokenRegistryStatus For all those verifiers the error happens during the test function (which determines if a verifier should run or not). The plan is to fix those test functions so that the verifiers doesn't run if issuers property (in that case) is not provided => the result for those verifiers will be skipped fragment. On top of that OpenAttestationHash verifier currently return invalid while it shouldn't run because targethash/merkleroot/data are missing => the plan is to fix this behaviour so that the verifier is skipped in that case. Also to make sure that verifiers test function handle correctly, we should provide a partial object (deeply) closes #111
3 verifiers trigger an error when an empty object is passed down: - OpenAttestationEthereumDocumentStoreStatus - OpenAttestationDnsTxt - OpenAttestationEthereumTokenRegistryStatus For all those verifiers the error happens during the test function (which determines if a verifier should run or not). The plan is to fix those test functions so that the verifiers doesn't run if issuers property (in that case) is not provided => the result for those verifiers will be skipped fragment. On top of that OpenAttestationHash verifier currently return invalid while it shouldn't run because targethash/merkleroot/data are missing => the plan is to fix this behaviour so that the verifier is skipped in that case. Also to make sure that verifiers test function handle correctly, we should provide a partial object (deeply) closes #111
🎉 This issue has been resolved in version 4.1.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Hi, noticed that
will throw an error because some validators are unable to find
issuers
data inside the empty object. Prevention of this behavior requires double-checking when validating, and that's not good. I assume that it's better to handle missing keys and just return proper validation error instead of plain JS error.The text was updated successfully, but these errors were encountered: