Merge lp:~benji/launchpadlib/delayed-keyring-import into lp:launchpadlib
Status: | Merged |
---|---|
Merged at revision: | 107 |
Proposed branch: | lp:~benji/launchpadlib/delayed-keyring-import |
Merge into: | lp:launchpadlib |
Diff against target: |
185 lines (+46/-14) 4 files modified
src/launchpadlib/credentials.py (+15/-1) src/launchpadlib/testing/helpers.py (+12/-2) src/launchpadlib/tests/test_http.py (+12/-5) src/launchpadlib/tests/test_launchpad.py (+7/-6) |
To merge this branch: | bzr merge lp:~benji/launchpadlib/delayed-keyring-import |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Henning Eggers (community) | code | Approve | |
Review via email: mp+45711@code.launchpad.net |
Description of the change
The keyring package initializes the back end storage at import time. If
the back end chosen is KDE, a couple of bad things happen: a dialog box
pops up asking for access to KWallet and a SIGCHLD handler is registered
which interferes with subprocess completion notification.
This branch delays the keyring import until the keyring is needed,
mitigating these problems. This approach has been approved by Leonard
and Gary.
This branch also eliminates the launchpadlib's test's usage of the real
keyring package because it introduces fragility and environment
dependencies into the test. The test suite also has enforcement that
ensures that non-testing keyring fakes are never used.
One class of test (SimulatedRespo
that these fixes exposed, those have been fixed as well.
The changes look good, thank you. I just wonder how the definition of "credential_ store_factory" relates to this. Is that supposed to be in here? Please have a look before you land this.