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

adding the sku in error message about sku with no associated stock #3356

Open
wants to merge 6 commits into
base: develop
Choose a base branch
from

Conversation

iphigenie
Copy link

Description (*)

The inventory module raises errors and exceptions that say

"The requested sku is not assigned to given stock."

As third party extensions and possibly some internal functions call these methods without isolating the exceptions (it should be possible to have products not associated to stock still shown on the site, just not buyable) one can sometimes find dozens and dozens of such error messages without any clarity whether it is one product causing them all or many different ones.

It would be more helpful is the SKU was added to the message.

This changes 2 i18n files and 4 model files to add the %1 variable so the message will contain the sku

Fixed Issues (if relevant)

Manual testing scenarios (*)

This is just a quality of life cosmetic change, making errors more informative.

Questions or comments

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds are green)

@iphigenie
Copy link
Author

iphigenie commented Aug 4, 2022

note that I have the same for the versions pushed with 2.4.4 and 2.4.3 releases but I haven't got a clue how to fork and pull request for a particular branch - and it'd only matter if there's a 2.4.5 coming

@iphigenie
Copy link
Author

Hi - I'd happily work at improving error messages so they are more useful in log but how do I get people to review and push? these are cosmetic QoL and should be super easy wins

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant