Merge lp:~danielalmaguer/wxbanker/Db_Fallback into lp:wxbanker
Status: | Needs review |
---|---|
Proposed branch: | lp:~danielalmaguer/wxbanker/Db_Fallback |
Merge into: | lp:wxbanker |
Diff against target: |
76 lines (+43/-2) 1 file modified
wxbanker/persistentstore.py (+43/-2) |
To merge this branch: | bzr merge lp:~danielalmaguer/wxbanker/Db_Fallback |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
wxBanker Developers | Pending | ||
Review via email: mp+142181@code.launchpad.net |
Description of the change
Thanks! I'll just propose a merge so we have a way to discuss the changes. Overall it looks great, just two suggestions. 1) for the GetLatestBackup function, it would be cleaner to simply sort the results of os.listdir and use the first/last result, using a custom "key" lambda a string sort doesn't do the trick.
2) when it calls DatabaseUpgrade
Thanks again for your time and contribution. Did you run into a database upgrade error that inspired this improvement? If so I'd love to know about it!
Thanks for your feedback. The Dialog informing the user and requesting him to file a bug has been implemented in DatabaseUpgrade Error() .
About optimizing the GetLatestBackup function, it's now done by using the sorted function as you suggested, but we didn't found an easy and neat way to implement the key function with the lambda feature, so we had to implement the function the normal way.
Any more feedback would be appreciated.
"Did you run into a database upgrade error that inspired this improvement?"
- Not really, I actually found wxBanker very useful and wanted to contribute, so I just jumped out to the buglist and saw this one.