New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Allow clearing modules cache for all shops #28445
Allow clearing modules cache for all shops #28445
Conversation
d43b557
to
da3d940
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A small feedback
5a655bf
to
d26b527
Compare
A small feedback |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A small comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@sowbiba If you have time for adding PHPDoc, it will be better
9bb1215
to
4a34c76
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @sowbiba
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A last feedback for inheritance
Co-authored-by: Progi1984 <progi1984@gmail.com>
Hello @sowbiba, The issue is a regression 1.7.8.0 so I think it should be fixed on 1.7.8.x branch.
on develop : When All shop is selected (we have only the options unistall and reset) When a specific shop is selected(we have the options : Disable Mobile/Disable/reset and Uninstall) on 1.7.8.x : When All shop is selected(we have the options : Disable Mobile/Disable/reset and Uninstall) When a specific shop is selected(we have the options : Disable Mobile/Disable/reset and Uninstall) Ping @PrestaShop/product-team Is it a wanted behavior? Thanks, |
I'm sorry @marwachelly but you are looking the wrong direction Here it's about the consistency of the module status for every shop (single shop context) In my example from the issue, the module is supposed to be disabled in the 2 shops but it's displayed as active in Shop1 and inactive for Shop2. If you remove the cache, the statuses are correct |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm sorry @marwachelly but you are looking the wrong direction The actions available are not the subject. Maybe there is an issue, I don't know
Here it's about the consistency of the module status for every shop (single shop context)
In my example from the issue, the module is supposed to be disabled in the 2 shops but it's displayed as active in Shop1 and inactive for Shop2. If you remove the cache, the statuses are correct
Hello @sowbiba,
Setting the module active / inactive in the develop branch in all shop context is not posssible. (When All shop is selected (we have only the options unistall and reset) So the bug is not reproducible on the branch develop.
Untitled_.May.30.2022.2_52.PM.mp4
The bug is reproducible also with PS 1.7.8.x and incognito browsing:
Untitled_.May.30.2022.3_33.PM.mp4
The bug is reproducible with PS1.7.7.8:
Untitled_.May.30.2022.3_41.PM.mp4
@PrestaShop/product-team Could you please check my comment above?
Thanks,
Hello @marwachelly |
Did you mean that? Untitled_.May.30.2022.3_45.PM.mp4But I think this is the expected behavior. The shop1 shouldn't have an influence on shop2. Isn't it? even with incognito browsing on develop and without PR i didn't manage to reproduce the issue Untitled_.May.30.2022.4_09.PM.mp4Did I miss something? Thanks, |
exactly you got it !! It's the expected behaviour because the module is coded like that For my module given in the example, the status is consistant between all the shops : disabling in one shop will make it disabled for the whole Backoffice. But I can't do this because of the cache which is not cleared after the actions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @sowbiba ,
PR is tested and the issue is fixed.
Untitled_.Jun.1.2022.4_36.PM.mp4
I detected an exception relaed to the module. As discussed in slack, the exception is not blocking the PR (just it is related to the module).
So PR is QA ✔️
Many thanks,
Thank you all ❤️ |
BC Breaks
ModuleRepository::clearCache now have a second optional parameter
$allShop
, boolean type, default to false, to allow clearing the cache for all the shops of the BO