-
Notifications
You must be signed in to change notification settings - Fork 516
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 error when removing a wallet on askar-profile #1518
Conversation
Signed-off-by: Ethan Sung <[email protected]>
Codecov Report
@@ Coverage Diff @@
## main #1518 +/- ##
=======================================
Coverage 95.70% 95.70%
=======================================
Files 521 521
Lines 32160 32165 +5
=======================================
+ Hits 30779 30784 +5
Misses 1381 1381 |
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.
I don't think this is correct. There are two separate instances of the multitenant manager that derive from base
- one is MultitenantManager
and one is AskarProfileMultitenantManager
. Both add loaded sub-wallets to the self._instances
array.
I suspect that the wrong instance type of the manager is getting loaded when running in askar
mode (i.e. MultitenantManager
instead of AskarProfileMultitenantManager
) and that's why self._instances
seems to be missing the sub-wallet profile.
Askar sub-wallets get added to |
@ianco Case 1. indy - basic Case 2. askar - basic Case 3. askar - askar-profile Case 1 and 2 use Case 3 uses The single profile ( This PR handles the Case 3. Thanks! |
Hi @baegjae thanks for the info! Since the behaviour of the MultitenantManager and AskarProfileMultitenantManager is different, I suggest to refactor the code to move the Maybe define a virtual method in the base class called |
Signed-off-by: Ethan Sung <[email protected]>
Signed-off-by: Ethan Sung <[email protected]>
Signed-off-by: Ethan Sung <[email protected]>
Signed-off-by: Ethan Sung <[email protected]>
Hi @ianco Also, I updated and added the unit test for this. Thanks! |
This PR fixes error when removing a wallet on askar-profile
Environment
askar-profile
Problem
Error occurred when removing a wallet.
Fix
Unlike other options, in askar-profile, the profiles of sub wallet are not stored in
self._instances
.However, current code always try to delete the profile in
self._instances
when removing a wallet.This PR resolves the above problem.
Thanks!
Signed-off-by: Ethan Sung [email protected]