Users get 403 because Lp has contradictory rules to unlink packages
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Launchpad itself |
Fix Released
|
Critical
|
Curtis Hovey |
Bug Description
Launchpad's zcml states that anyone can unlink a package from a series. The rule is used on the distrribution and source package pages, and on the project's package pages. When translation message sharing was added, a condition was added to the code that will raise a forbidden error if the user attempts to unlink a package from a series that is sharing translations.
A. When the rule was added, all places that show the remove packaging links should have been updated to use the code rules. so that Lp does not lie to users. I see a nominal attempt to guard the links on the source package's menu, which is seen less often than the DSP's page.
B. I think the code rule is wrong. Packaging.
If the link is wrong, anyone should be permitted to remove it. I think the restriction exists to prevent accidental loss of translations, and that could be solved by asking the user to confirm the the series with translations must be removed. The confirmation is not needed is the series is linked to several packages. There already is a confirmation page, all that is needed is an explanation that translations are shared, do you still want to remove the packaging link?
Related branches
- Richard Harding (community): Approve
-
Diff: 642 lines (+86/-199)11 files modifiedlib/lp/registry/browser/tests/test_sourcepackage_views.py (+28/-31)
lib/lp/registry/doc/sourcepackage.txt (+0/-64)
lib/lp/registry/interfaces/packaging.py (+2/-3)
lib/lp/registry/model/packaging.py (+7/-6)
lib/lp/registry/stories/packaging/xx-distributionsourcepackage-packaging-concurrent-deletion.txt (+2/-2)
lib/lp/registry/stories/packaging/xx-distributionsourcepackage-packaging.txt (+2/-1)
lib/lp/registry/tests/test_packaging.py (+9/-20)
lib/lp/registry/tests/test_sourcepackage.py (+16/-59)
lib/lp/testing/factory.py (+6/-1)
lib/lp/translations/browser/tests/test_sharing_details.py (+12/-11)
lib/lp/translations/tests/test_translationpackagingjob.py (+2/-1)
summary: |
- Users get 503 because Lp has contradictory rules to unlink packages + Users get 403 because Lp has contradictory rules to unlink packages |
description: | updated |
tags: | added: regression |
Changed in launchpad: | |
assignee: | nobody → Curtis Hovey (sinzui) |
status: | Triaged → In Progress |
tags: |
added: qa-ok removed: qa-needstesting |
Changed in launchpad: | |
status: | Fix Committed → Fix Released |
Fixed in stable r15987 <http:// bazaar. launchpad. net/~launchpad- pqm/launchpad/ stable/ revision/ 15987>.