Problem/Motivation
The ProjectInfo class still expects base themes to be not installed (this was changed in #1067408: Themes do not have an installation status)
Proposed resolution
Remove all the handling of base themes and sub themes since this is now irrelevant as themes have to be installed.
There is a slight logic change: if a project (module or theme) is hidden but installed and not in the testing package then it will be reported on. This is because bast themes are often hidden so they don't show on the appearance page. We could limit this to themes only BUT it makes sense for modules too. If a hidden, installed module has security updates we should report this.
Remaining tasks
Write patch
Review commit
User interface changes
No longer report on base themes and sub themes. They will be reported on as regular projects because they are installed.
API changes
None - i think all the changes are internal and removing redundant code.
Comment | File | Size | Author |
---|---|---|---|
#15 | 2338167-2.15.patch | 13.73 KB | alexpott |
#15 | 11-15-interdiff.txt | 6.1 KB | alexpott |
#11 | 2338167-2.11.patch | 8.07 KB | alexpott |
#11 | 9-11-interdiff.txt | 874 bytes | alexpott |
#9 | 2338167-2.9.patch | 7.75 KB | alexpott |
Comments
Comment #1
BerdirComment #2
bogdan.racz CreditAttribution: bogdan.racz commentedI have been working on the issue 2470145. As I searched for other places where this might impact, I came across some code&comments in this class, which don't reflect the changes. Can I invest more time into this?
Comment #3
xjmRemoving a tag that isn't used in core.
Comment #4
bogdan.racz CreditAttribution: bogdan.racz commentedI spoked with alexpott, and for now, until the release I just posted a patch for documenting and setting a default value for the deprecated "status" variable.
Comment #5
bogdan.racz CreditAttribution: bogdan.racz commentedComment #7
bogdan.racz CreditAttribution: bogdan.racz commentedThis patch cannot work, until the issue 2470145 is fixed. I tested with the patch from the issue above and it works.
Anyhow it should be retested after the usability issue above is considered fixed.
Comment #9
alexpottSo now all themes needs an installation status we can just remove all the complexity about handling sub themes and base themes. All themes depend on their base themes and a base theme has to be installed for one of it's sub themes to be. Therefore themes are just like modules and can be treated as such! (Yay!).
Drupal\update\Tests\UpdateContribTest
has extensive testing of the relationships between base themes and sub themes so this works out really nicely.Comment #11
alexpottSo the patch slightly modifies the behaviour when it comes to hidden projects. We need to exclude hidden test projects here.
This patch does make a slight but significant change - if a project is hidden but is not in the test package and is enabled it's security updates will show. This was the old behaviour for base themes but I think it should be extended for all. If a project is installed and has security updates you need to know this regardless of the hiddenness.
Comment #12
alexpottI'm going to make this issue only focus on base themes - since it is a separate issue from the use of the word disabled.
Comment #13
alexpottComment #14
Wim LeersMakes sense.
The patch itself looks great. So I had to review this by applying and looking at the touched files, to see if everything that should be updated is indeed updated. That's how I found the following:
ProjectInfo
:This TODO should be removed :)
ProjectInfo
:This needs to be updated. It will be much simpler now :)
update.report.inc
:I think all of this can be deleted too?
Comment #15
alexpott@Wim Leers thanks for the review.
I've added tests around the new behaviour for hidden projects.
Comment #16
Wim LeersGreat!
Just nits that can be fixed on commit:
Nit: s/in the Testing/in the Testing package/
Nit: s/testing/Testing/
Comment #18
catchCommitted/pushed to 8.0.x, thanks! (fixed those two nits on commit).
Comment #19
joelpittetAlbeit not easy or obvious to get to:
Does this mean we no longer show the base theme to child theme relationship anywhere in core?
Just to give a use-case: if I were to use bootstrap theme and it has updates, it would be nice to know that upgrading that may affect my child theme.
Comment #20
joelpittetMaybe this issue will half help: #2372183: Display same info for themes as for modules, @davidhernandez mentioned it to me.
Comment #21
alexpottI don't think it is the job of the update status report to report the relationship between themes. It does not for modules. If this the update status report should display dependency information then it should do so for both module and themes. Since if the "nice to know" argument applies to themes it applies to modules. The reason base themes and sub themes where displayed in D7 was because (freakishly) there was no requirement for a theme to be enabled for it to be actually used.
Comment #22
joelpittetI guess that is why that other issue exists #2372183: Display same info for themes as for modules because it should apply to both. I think the use-case I mentioned is valid in both theme and module dependency cases.