-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
Magento 2.4.5: Show Out Of Stock option outputs all available products during search #36055
Comments
Hi @pmonosolo. Thank you for your report.
Make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, Add a comment to the issue:
For more details, review the Magento Contributor Assistant documentation. Add a comment to assign the issue: To learn more about issue processing workflow, refer to the Code Contributions.
🕙 You can find the schedule on the Magento Community Calendar page. 📞 The triage of issues happens in the queue order. If you want to speed up the delivery of your contribution, join the Community Contributions Triage session to discuss the appropriate ticket. ✏️ Feel free to post questions/proposals/feedback related to the Community Contributions Triage process to the corresponding Slack Channel |
@magento give me 2.4-develop instance |
Hi @pmonosolo. Thank you for your request. I'm working on Magento instance for you. |
Hi @pmonosolo, here is your Magento Instance: https://2a84a4e16655dab06981be102116addf.instances.magento-community.engineering |
@magento give me 2.4.3 instance |
Hi @pmonosolo. Thank you for your request. I'm working on Magento instance for you. |
Hi @pmonosolo, here is your Magento Instance: https://a8564c0d1a87b370b3d016bd8a0ccd93.instances.magento-community.engineering |
Magento 2.4.3 does not have this issue: |
It looks like the fix for this issue is in this thread: I need to test a bit more, but so far, it's outputting only the items in the search. |
Probably fixed in #35986 |
Hmmm, doesnt seem to work. The page loading time is still slow. The fix in vendor\magento\module-inventory-catalog\Plugin\Catalog\Block\ProductList\UpdateToolbarCount.php It looks like somebody by mistake is calling wrong method - it pulls the WHOLE product collection rather than a collection related to the search. I need to test other parts of the catalog page in case there's some hidden issue thats not related to search. Although, it should not be really working. The whole piece of code is being skipped: So this fix migth work for single store with one view, but for others not so much. |
The both solutions for me doesn't work :
I am on Magento 2.4.5 and PHP 8.1. |
Search for their name in the issues, I believe I've seen somebody working on this issue for that specific plugin. |
Thank you @pmonosolo for your heads up. Indeed, I found Smile-SA/elasticsuite#2663 (comment) but it is the same solution as magento/inventory#3360. |
Ah, I just disabled that Plugin. They need to rewrite that to check for:
Currently it just checks the Category page, so on Search Page it uses "Default Category" and outputs the whole catalog. When you filter by attributes, it does not decrease the number because the only lookup that is done is for Category. It does not check if filters were applied to the category. |
Hi @engcom-Lima. Thank you for working on this issue.
|
@magento give me 2.4.5 instance |
Hi @engcom-Lima. Thank you for your request. I'm working on Magento instance for you. |
Hi @engcom-Lima, here is your Magento Instance: https://615b269acd08405a876118d0c2ac995b.instances.magento-community.engineering |
@magento give me 2.4-develop instance |
Hi @engcom-Lima. Thank you for your request. I'm working on Magento instance for you. |
Hi @engcom-Lima, here is your Magento Instance: https://2a84a4e16655dab06981be102116addf.instances.magento-community.engineering |
✔️ Issue confirmed Issue got reproduced in Magento 2.4-develop and 2.4.5 Description: Pre-requisite: Steps to reproduce:
Expected result: It should show 2 items for ryker product. Actual result: It is showing 187 items as shown in screenshot below: |
✅ Jira issue https://jira.corp.adobe.com/browse/AC-6768 is successfully created for this GitHub issue. |
✅ Confirmed by @engcom-Lima. Thank you for verifying the issue. |
Thanks @engcom-Lima ! The issue is not really in the number, its the time it takes to pull the number of the products. If you have a 300,000 sku store, this is an issue because it outputs the whole catalog 300,000 products on a search page, for EVERY search! This is why I think there should be two sample data types - one for small store (1000), one for big store (300,000 skus). Some difficult to detect issues are more visible on big stores only. |
Preconditions and environment
On website I'm working on to upgrade to 2.4.5 from 2.4.3, the Catalog Search ouputs the whole Enabled Catalog:
Instead of only ouputting the search results which should be 664 items:
Sorry bad screenshots because I was pulling the store apart to try to understand where it's coming from.
This can sort of be replicated on Vanilla Magento 2.4.5 with test data.
Here are the settings:
Catalog - > Inventory
This is the main culprit (Display Out Of Stock Products = YES)
I believe there are some settings in the Catalog section that are also affecting the issue:
Catalog - > Catalog
Steps to reproduce
/catalogsearch/result/?q=ryker
Expected result
Two items are shown:
Actual result
But it shows two items and toolbar shows "181 items":
Additional information
On my site this is creating a problem because each search instead of 2 seconds, becomes a 22 second search. HELP!
Release note
No response
Triage and priority
The text was updated successfully, but these errors were encountered: