Merge lp://staging/~mvo/software-center/webapps-activation into lp://staging/software-center

Proposed by Michael Vogt
Status: Merged
Merged at revision: 3278
Proposed branch: lp://staging/~mvo/software-center/webapps-activation
Merge into: lp://staging/software-center
Diff against target: 296 lines (+166/-7)
9 files modified
setup.py (+3/-2)
softwarecenter/db/pkginfo.py (+4/-0)
softwarecenter/db/pkginfo_impl/aptcache.py (+4/-0)
softwarecenter/paths.py (+1/-0)
softwarecenter/plugin.py (+1/-0)
softwarecenter/plugins/webapps_activation.py (+57/-0)
tests/test_region.py (+1/-0)
tests/test_webapps_activation_plugin.py (+90/-0)
tests/utils.py (+5/-5)
To merge this branch: bzr merge lp://staging/~mvo/software-center/webapps-activation
Reviewer Review Type Date Requested Status
dobey Approve
Michael Vogt (community) Needs Resubmitting
Review via email: mp+134459@code.staging.launchpad.net

Description of the change

This add support to activate webapps automatically on install.

To post a comment you must log in.
Revision history for this message
dobey (dobey) wrote :

134 + def activate_unity_webapp_for_domain(self, domain):
135 + try:
136 + from gi.repository import UnityWebapps
137 + except ImportError:
138 + LOG.warn("failed to import UnityWebapps GIR")
139 + LOG.debug("activating webapp for domain '%s'", domain)
140 + UnityWebapps.permissions_allow_domain(domain)

The last two lines in this function need to be inside an else: I think. Otherwise an exception will be raised when permissions_allow_domain() is called, if the import failed, since you're not returning in the except handler. I guess this wasn't caught in your tests, as you're mocking that function.

+ # instal backend

Typo.

review: Needs Fixing
3243. By Michael Vogt

softwarecenter/plugins/webapps_activation.py: if UnityWebapps GIR can not be imported, just return (thanks to Rodney Dawes!)

Revision history for this message
Michael Vogt (mvo) wrote :

Thanks a lot Rodney!

Indeed, the import failure was not tested and I overlooked it, fixed in r3243 now. I also fixed the typo now.

review: Needs Resubmitting
Revision history for this message
dobey (dobey) wrote :

There's a text conflict in softwarecenter/paths.py now.

3244. By Michael Vogt

tests/test_webapps_activation_plugin.py: fix typo, thanks dobey

3245. By Michael Vogt

merged trunk and resolved conflicts

Revision history for this message
Michael Vogt (mvo) wrote :

Thanks again, I fixed the conflict and pushed the typo fix.

Revision history for this message
dobey (dobey) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches