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

Fix issue #4470: allow numbers in vendor and class names #11062

Closed
wants to merge 4 commits into from

Conversation

nhp
Copy link

@nhp nhp commented Sep 26, 2017

As there are many companies that use numbers in their name it would be good to allow those to use them in their classes and vendor names.

Description

To enable a widely used naming scheme, with numbers, the xsd files needed to be adapted else the names could not be validated

Fixed Issues (if relevant)

  1. import.xml doesn't allow numbers in vendor name and class name #4470: import.xsd doesn't allow numbers in vendor name and class name

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 on Travis CI are green)

heyitsroberthe and others added 4 commits September 12, 2017 20:36
[mpi] MAGETWO-72551: Update version in composer to 2.2.1-dev for 2.2-develop branch
To be consistent with the enhanced xsd schemas the tests needed to be
adapted.
The problem is, that there is a difference between what you can use as
Model an what is validated by the xsd file.
@orlangur orlangur self-assigned this Sep 26, 2017
@orlangur
Copy link
Contributor

Any idea why we need underscore allowed?

@vrann vrann self-assigned this Sep 27, 2017
@vrann vrann added this to the September 2017 milestone Sep 27, 2017
@orlangur orlangur removed their assignment Sep 27, 2017
@vrann vrann reopened this Sep 29, 2017
@magento-cicd2
Copy link
Contributor

magento-cicd2 commented Sep 29, 2017

CLA assistant check
Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
1 out of 3 committers have signed the CLA.

✅ nhp
❌ paliarush
❌ viktym

@vkublytskyi
Copy link

@nhp thank you for this contribution.

Provided regex allows invalid value such as 1invalidClassName. As Model name potentially could be any valid PHP class name (FQCN to be precise) and according to PHP documentation full regexp should looks like:

(?:\\?[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*)+

@magento-engcom-team magento-engcom-team added 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 Reproduced on 2.1.x The issue has been reproduced on latest 2.1 release labels Nov 28, 2017
@orlangur orlangur self-assigned this Nov 30, 2017
@magento-engcom-team
Copy link
Contributor

Hi @nhp
We are closing this Pull Request now due to inactivity. Additionally, some misplaced commits are present in changeset at the moment.

If you wish to proceed please create a new PR or reopen this one fixing up the history.

Thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bugfix Component: Setup 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 Progress: needs update Release Line: 2.2 Reproduced on 2.1.x The issue has been reproduced on latest 2.1 release
Projects
None yet
Development

Successfully merging this pull request may close these issues.