Skip to content
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

Closes #6851: 3.17 refactor regression: {wpr_imagedimensions=1} query string isnot added to home page while warmup after fresh install #6853

Conversation

jeawhanlee
Copy link
Contributor

@jeawhanlee jeawhanlee commented Aug 7, 2024

Description

Fixes #6851

Documentation

User documentation

Imagedimension query argument is now added for home during activation, this initially prevent the home from having entries in DB

Technical documentation

In the 3.17 refactor we removed these lines and depended on the filter to apply this query arg here but the issue was that the warmup subscriber will not be loaded early enough for this callback to be fired, so in this PR we loaded the subscriber early enough to trigger the callback.

Type of change

  • Bug fix (non-breaking change which fixes an issue).

New dependencies

None

Risks

None

Checklists

Feature validation

  • I validated all the Acceptance Criteria. If possible, provide sreenshots or videos.
  • I triggered all changed lines of code at least once without new errors/warnings/notices.

Documentation

  • I prepared the user documentation for the feature/enhancement and shared it in the PR or the GitHub issue.
  • The user documentation covers new/changed entry points (endpoints, WP hooks, configuration files, ...).
  • I prepared the technical documentation if needed, and shared it in the PR or the GitHub issue.

Code style

  • I wrote self-explanatory code about what it does.
  • I named variables and functions explicitely.
  • I did not introduce unecessary complexity.

@jeawhanlee jeawhanlee self-assigned this Aug 7, 2024
Copy link

codacy-production bot commented Aug 7, 2024

Coverage summary from Codacy

See diff coverage on Codacy

Coverage variation Diff coverage
+0.00% (target: -0.10%) 0.00% (target: 50.00%)
Coverage variation details
Coverable lines Covered lines Coverage
Common ancestor commit (cb76df6) 37542 14268 38.01%
Head commit (cb5fb17) 37546 (+4) 14268 (+0) 38.00% (+0.00%)

Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: <coverage of head commit> - <coverage of common ancestor commit>

Diff coverage details
Coverable lines Covered lines Diff coverage
Pull request (#6853) 5 0 0.00%

Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: <covered lines added or modified>/<coverable lines added or modified> * 100%

See your quality gate settings    Change summary preferences

Codacy stopped sending the deprecated coverage status on June 5th, 2024. Learn more

@jeawhanlee jeawhanlee changed the title Closes #6852: 3.17 refactor regression: {wpr_imagedimensions=1} query string isnot added to home page while warmup after fresh install Closes #6851: 3.17 refactor regression: {wpr_imagedimensions=1} query string isnot added to home page while warmup after fresh install Aug 7, 2024
@jeawhanlee jeawhanlee marked this pull request as ready for review August 7, 2024 11:16
@jeawhanlee jeawhanlee requested a review from a team August 7, 2024 11:16
@jeawhanlee jeawhanlee changed the base branch from develop to 3.17-atf-refactor August 7, 2024 11:16
@remyperona
Copy link
Contributor

Question: What is the advantage of this solution instead of reverting to the previous working code?

@jeawhanlee
Copy link
Contributor Author

@Tabrisrp We define this query before in 2 places, in the api client and also as a callback which didn't seem necessary but now we still have it defined once but just with the subscriber called early enough.

Copy link

@hanna-meda hanna-meda left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested and confirmed as fixed on PR.

@jeawhanlee jeawhanlee merged commit 10b0b65 into 3.17-atf-refactor Aug 8, 2024
2 checks passed
@jeawhanlee jeawhanlee deleted the fix/6852-regression-image-dimension-not-added-to-home-during-warmup-on-activation branch August 8, 2024 08:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants