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

Trim whitespace on SKU when saving product #16572

Closed
Zyles opened this issue Jul 5, 2018 · 10 comments
Closed

Trim whitespace on SKU when saving product #16572

Zyles opened this issue Jul 5, 2018 · 10 comments
Assignees
Labels
Component: Catalog Event: squashtoberfest Fixed in 2.2.x The issue has been fixed in 2.2 release line Fixed in 2.3.x The issue has been fixed in 2.3 release line good first issue Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release

Comments

@Zyles
Copy link

Zyles commented Jul 5, 2018

Preconditions

Magento 2.2

Steps to reproduce

Save or update product in admin with a space at beginning or end.

Expected result

Trim excessive whitespace at beginning and end of SKU

Actual result

Whitespace SKU saved in DB.

The actual problem

When you accidentally save a product with whitespaced SKUs it can become a future problem when syncing data, importing images, or any other process because the SKU was correct but a space was accidentally added.

When doing syncing you could end up with duplicate products with good inventory systems that actually trim the SKU.

The GUI text field itself is padded which can lead to store managers not noticing an accidental extra space.

Is there an applicable real world reason for a space at the beginning of an SKU (and the end)? Why is it allowed?

@magento-engcom-team magento-engcom-team added the Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed label Jul 5, 2018
@magento-engcom-team
Copy link
Contributor

magento-engcom-team commented Jul 5, 2018

Hi @Zyles. Thank you for your report.
To help us process this issue please make sure that you provided the following information:

  • Summary of the issue
  • Information on your environment
  • Steps to reproduce
  • Expected and actual results

Please make sure that the issue is reproducible on the vanilla Magento instance following Steps to reproduce. To deploy vanilla Magento instance on our environment, please, add a comment to the issue:

@magento-engcom-team give me {$VERSION} instance

where {$VERSION} is version tags (starting from 2.2.0+) or develop branches (2.2-develop +).
For more details, please, review the Magento Contributor Assistant documentation.

@Zyles do you confirm that you was able to reproduce the issue on vanilla Magento instance following steps to reproduce?

  • yes
  • no

@engcom-backlog-nickolas engcom-backlog-nickolas added Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release labels Jul 6, 2018
@engcom-backlog-nickolas
Copy link

Hello @Zyles, thank you for your report.
We've acknowledged the issue and added to our backlog.

@wstnbrg
Copy link

wstnbrg commented Oct 6, 2018

#squashtoberfest

@magento-engcom-team
Copy link
Contributor

@wstnbrg thank you for joining. Please accept team invitation here and self-assign the issue.

@wstnbrg wstnbrg self-assigned this Oct 6, 2018
@wstnbrg
Copy link

wstnbrg commented Oct 6, 2018

@magento-engcom-team give me 2.3-develop instance

@magento-engcom-team
Copy link
Contributor

Hi @wstnbrg. Thank you for your request. I'm working on Magento 2.3-develop instance for you

@magento-engcom-team
Copy link
Contributor

Hi @wstnbrg, here is your Magento instance.
Admin access: https://i-16572-2-3-develop.engcom.dev.magento.com/admin
Login: admin Password: 123123q
Instance will be terminated in up to 3 hours.

@sidolov sidolov added the Fixed in 2.3.x The issue has been fixed in 2.3 release line label Oct 27, 2018
@sidolov
Copy link
Contributor

sidolov commented Oct 27, 2018

Hi @Zyles. Thank you for your report.
The issue has been fixed in #18019 by @bartoszkubicki in 2.3-develop branch
Related commit(s):

The fix will be available with the upcoming 2.3.1 release.

@magento-engcom-team
Copy link
Contributor

Hi @Zyles. Thank you for your report.
The issue has been fixed in #18862 by @gelanivishal in 2.2-develop branch
Related commit(s):

The fix will be available with the upcoming 2.2.8 release.

@magento-engcom-team magento-engcom-team added the Fixed in 2.2.x The issue has been fixed in 2.2 release line label Oct 29, 2018
@Zyles
Copy link
Author

Zyles commented Oct 29, 2018

Good, thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Catalog Event: squashtoberfest Fixed in 2.2.x The issue has been fixed in 2.2 release line Fixed in 2.3.x The issue has been fixed in 2.3 release line good first issue Issue: Clear Description Gate 2 Passed. Manual verification of the issue description passed Issue: Confirmed Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development Reproduced on 2.2.x The issue has been reproduced on latest 2.2 release Reproduced on 2.3.x The issue has been reproduced on latest 2.3 release
Projects
None yet
Development

No branches or pull requests

8 participants