-
Notifications
You must be signed in to change notification settings - Fork 9
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
fix: bump ew-credentials to 2.2.1-alpha.296.0 #662
Conversation
|
@JGiter currently ew-credentials error pattern is to return 'boolean, string' to ICL. If we want to implement the above, we will need to do some string parsing to 1.) determine that this error is for not having authoritative credential and 2.) then pull out the actual role name. and then 3.) pass the role to check if the user has it. Unless there is a different way, or we want to change how we are handling errors. I feel we could achieve almost the same result by checking if the error is 'no authoritative credential found' and then adding "If you do not have this role, you must obtain it. If you already have this role, please publish it." But, happy to either update how we handle the errors (If we want to get the role and check for it, I suggest we change the ew-credential error to an object) or do regex parsing if we don't want to go this route but still want to check if the user has this role. Let me know if I'm missing something here. Thanks. |
Do you mean error thrown during issuance? I think that the purpose of this task is to exlude such errors. So that when issuer receives request to issue, then issuance happens without any issues |
My last comment doesn't correspond to actual task description which say about error handling, but nevertheless I think we should be move toward avoiding error |
But yes, if error happend you can append it with message saying that issuer role needs to be published and rethrow |
At this point we don't know if it needs to be published, or if he has not enrolled in the role at all. I think we should throw an error saying "No authorative credential found for issuer for role "installer.role...". If you do not have this role, you must obtain it. If you do have this role, please publish it." Either way on SB, it will appear in the red error box. There is no other UI treatment right now for caught errors. That would be an addition to this task I think. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Seems good to me
## [7.0.0-alpha.3](v7.0.0-alpha.2...v7.0.0-alpha.3) (2022-09-22) ### Bug Fixes * bump ew-credentials to 2.2.1-alpha.296.0 ([#662](#662)) ([9af689c](9af689c))
🎉 This PR is included in version 7.0.0-alpha.3 🎉 The release is available on: Your semantic-release bot 📦🚀 |
## [7.0.0](v6.2.0...v7.0.0) (2022-12-06) ### ⚠ BREAKING CHANGES * **claims:** Payload of selfsigned claim is arbitrary object ### Bug Fixes * bump ew-credentials to 2.2.1-alpha.296.0 ([#662](#662)) ([9af689c](9af689c)) * **claims:** change selfsigned claim to record ([9986876](9986876)) * commit for 2c0a860 ([45cdac0](45cdac0)) * publish assets on-chain ([#654](#654)) ([2c0a860](2c0a860)) * verify credential before issuer verification ([111923b](111923b)) ### Refactoring * **claims:** merge ClaimData with vc-verification ([0e1fafa](0e1fafa)) ### Documentation * add asset credential registration to documentation ([ba6f7ba](ba6f7ba)) ### Style changes * add warn for shadow variables (variables in scope that share s… ([#663](#663)) ([dd28b49](dd28b49))
🎉 This PR is included in version 7.0.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Description
@jrhender and @JGiter It sounded from the story that you wanted to add more info to this error. Should ICL catch the error from verifyIssuer, and if the error contains this text return it with more descriptive error message such as 'No authorative credential found for issuer for role "installer.role...". You must obtain and publish this role before approving this request.'
Or should we just throw this new error?
Update - we will just return this error and in the future address the root issue that SSI hub returns role approval requests that a user is not authorized to approve due to not having/publishing role
Contributor checklist