-
-
Notifications
You must be signed in to change notification settings - Fork 270
Conversation
Replace refreshPasswordList and resetPasswordList with a single function that resets navigation only if necessary, namely if the current directory no longer exists. This function is now also called mostly from PasswordStore, whereas previously refresh and reset calls were made from many different places in the code base, sometimes twice, sometimes ineffectively. There is a remaining issue to fix: The sync operation does not return with the correct request code (105), but with 65535. As a result, as before, no refresh/reset happens after a sync operation while everything works as expected after a pull operation.
Hm I think I encountered this while refactoring PasswordStore to use ActivityResultContracts, I'll push a fix to this PR when I get to my PC for testing this. |
* develop: Update Public Suffix List data (#888)
20 minutes of frustrating println debugging later I got nothing :/ |
It is really weird that the behavior differs between sync and pull. I don't see any activity-related difference between the two operations. If we really can't figure this out, how about adding a fixme comment and calling reset in an else branch? It's ugly, but I'm out of other ideas. |
Yeah I think that's gonna do for now, hopefully ActivityResultContracts will eliminate this when I finish the migration. |
* develop: UI fixups (#892)
The refresh is also run when an unexpected request code is encountered (with an appropriate FIXME comment). |
📢 Type of change
📜 Description
Replace refreshPasswordList and resetPasswordList with a single function that resets navigation only if necessary, namely if the
current directory no longer exists.
This function is now also called mostly from PasswordStore, whereas previously refresh and reset calls were made from many different places in the code base, sometimes twice, sometimes ineffectively.
@msfjarvis There is a remaining issue to fix: The sync operation does not return with the correct request code (105), but with 65535. As a result, just as before, no refresh/reset happens after a sync operation while everything works as expected after a pull operation.
💡 Motivation and Context
Password list refresh and reset is currently handled all over the place in our code base and not handled correctly in all cases.
💚 How did you test it?
I verified that the correct kind of refresh is performed after moves, password creations, push and pull operations, but this needs more testing.
📝 Checklist
🔮 Next steps
Come up with a good changelog entry once we know whether we can fix the sync issue.
📸 Screenshots / GIFs