SlideShare a Scribd company logo
1 of 40
#MM19IN
#MM19IN
Neeta Kangiya
Extension Submission to Magento
Marketplace
#MM19IN
Magento
Module
Theme Language
Pack
Magento2 Package ?
#MM19IN
Marketplace
An official application store of Magento
#MM19IN
Reasons to Sell Package on Marketplace
Centralized space to manage your products
Magento users trust marketplace and plugins themes listed on that
By being on marketplace you increase brand’s value and its credibility
#MM19IN
Enter into Marketplace
• To submit an extension to Marketplace, you have to
be a registered user. So, first, go
to marketplace.Magento.com and create an account.
• Once you finished the registration, you can move on
to a package submission.
#MM19IN
#MM19IN
Two Stages Package will go through
Technical
Submission
Marketing
Review
#MM19IN
Technical
Submission
Validate your code
through predefine
tools
Manual QA
Process
#MM19IN
Code Review using Tools
 Verify Package for Required Files
 Coding Standards: Check Code Quality/Syntax
 Installation (M2 only): Verify that Product
Installs Correctly
#MM19IN
 Intellectual Property: Check for Plagiarism
 Page Caching (M2 only): Verify that Varnish
Works Correctly
Code Review using Tools
#MM19IN
Advantage of Code Review using Tools
Minimize back and forth process for
submission of extension to the
marketplace
#MM19IN
The validation tool to test the package before it is
submitted to Magento Marketplace.
To download the tool, see the Marketplace Tools GitHub
repository.
Verify Package for Required Files
#MM19IN
Required Files
All composer.json
registration.php
Module etc/module.xml
Theme theme.xml
Language Pack language.xml
Metapackage composer.json
#MM19IN
Usage of validate_m2_package.php
validate_m2_package [OPTIONS] <M2 zip file>
[<M2 zip file> ...]
-h help Prints this usage.
-d debug Optional - prints additional debug
messages.
Verify Package for Required Files
#MM19IN
silent on success unless the debug option is set
ERROR - "<zip file name>": Error message.
Errors must be fixed, warnings and notes are purely
informational.
Can fix any warnings or notes but is not required
to.
Verify Package for Required Files
#MM19IN
#MM19IN
EQP – Extension Quality Program - a set of rules
and sniffs for PHP_CodeSniffer
Automatically check your code against some of the
common Magento and PHP coding issues
Coding Standards: Check Code
Quality/Syntax
#MM19IN
• raw SQL queries;
Example : SELECT * from catalog_entity;
• Direct class instantiation;
Example : $className =
MagentoCatalogModelProduct;
Coding Standards: Check Code
Quality/Syntax
#MM19IN
• use of PHP superglobals;
Example: '$_GET', '$_POST', '$_SESSION',
'$_REQUEST', '$_ENV', '$_FILES‘
• use of dangerous functions
Example: eval()
many more …
Coding Standards: Check Code
Quality/Syntax
#MM19IN
https://github.com/Magento/marketplace-eqp
$ vendor/bin/phpcs /path/to/your/extension --standard=MEQP2
Example :
$ vendor/bin/phpcs /app/code/Wagento/TestModule --standard=MEQP2
Coding Standards: Check Code
Quality/Syntax
#MM19IN
Coding Standards: Check Code
Quality/Syntax
SEVERITY10
SEVERITY8
SEVERITY 6
#MM19IN
Coding Standards: Check Code Quality/Syntax
TYPE SEVERITY DESCRIPTION MUST BE
RESOLVED?
Examples - NOT TO BE
USED IN CODE
Error 10 A critical error with
severity level 10
Yes
• The opening PHP
tag must be the first
• Namespace not
specified
• Use of goto
• Use of exit and
echo
• Use of Super
globals
• Closing tag should
not there
• Use of eval()
#MM19IN
Coding Standards: Check Code Quality/Syntax
TYPE SEVERITY DESCRIPTION MUST BE
RESOLVED?
Examples - NOT TO
BE USED IN CODE
Warning
8 A severity level 8
warning
Developers are
encouraged
to solve
• Long array syntax
• Direct Object
instantiation
• Direct throw of
exception
• Use of + operator
to concate two
string
• Nesting level of
function exceeds
5, refactor
function
• Use the global
keyword
#MM19IN
Coding Standards: Check Code Quality/Syntax
TYPE SEVERITY DESCRIPTION MUST BE
RESOLVED?
Examples NOT TO BE
USED IN CODE
Warning 6 A severity level 6
warning
Developers are
encouraged to
solve
• Unused Function
Parameter
• Useless Overriding
Method
• Commenting Todo
Comment Found
• Empty Block
Detected ELSE
• Files Line Length
Max Exceeded
• Function Call
Argument Spacing
• Disallow Short Open
Tag
#MM19IN
• Magento Marketplace Technical Review run phpcs
command with
--severity=10 option.
• Example
$ vendor/bin/phpcs /path/to/your/extension --
standard=MEQP2 --severity=10 --extensions=php,phtml
Coding Standards: Check Code
Quality/Syntax
#MM19IN
#MM19IN
• Extension code contains source code from the Magento
CE of Magento 1.x or 2.x platforms, the extension must
be licensed under Open Source License v. 3.0
• Properly credit to Magento Commerce.
Plagiarism
#MM19IN
• Installs with Composer,
• Compiles without errors using the following command:
deploy:mode:set production
• Works with each version of Magento that is shown as supported in the
extension product profile.
• Works with each version of PHP that is supported by the Magento
version that is shown as supported in the extension product profile.
Quality Assurance : Pass Manual QA
#MM19IN
• Has all functionality that is described in the extension documentation.
• Does not crash with unhandled errors.
• Does not hang when invalid data is submitted.
Quality Assurance : Pass Manual QA
#MM19IN
• Varnish Test The Production Installation Test (see above)
will be done on Magento 2 with Varnish cache
• Any unexpected cache misses will be considered a failure
• cacheable= false must not be used within the blocks
where core Magento is caching the blocks
https://devdocs.Magento.com/guides/v2.2/config-
guide/varnish/config-varnish.html
Varnish Testing
#MM19IN
• Place store in Developer Mode
• Inspect the page headers in your browsers debug network
tab.
• Look forX-Magento-Cache-Debug: MISS
• Refresh the page, it should change to HIT
Recommended to check for Product detail page ,
customer account pages etc
Varnish Testing
#MM19IN
When we add cachable="false"
X-Magento-Cache-Debug:MISS
X-Magento-Cache-Control:max-age=0, must-revalidate, no-cache, no-
store
Age: 0
When we remove cacheable="false"
X-Magento-Cache-Control:max-age=86400, public, s-maxage=86400
X-Magento-Cache-Debug:HIT X-Magento-Cache-Hits:1
Age:32
Varnish Testing
#MM19IN
Marketing Review
Solve a business problem and deliver
rich and unique functionality
#MM19IN
Marketing Review
 Spell-check all text fields and product documentation
 Pricing: Complete pricing information
 Content: Complete brief & detailed description
 Branding: Follow Magento brand and logo guidelines
#MM19IN
Marketing Review
• Your product must have a professional presentation with
clear descriptions, images, and screenshots.
• The product name should indicate the purpose of the
extension or theme.
• The product description should be well-written, and provide
an overview of the features and benefits.
• Use only high-quality screenshots, images, and video to
accompany the listing.
#MM19IN
Contribution Program for EQP
Please feel free to contribute new sniffs or
any fixes or improvements for the existing ones.
#MM19IN
Contribution Program for EQP
#MM19IN
Contribution Program for EQP
You can get latest updates by slack channel of
coding-standards on Magento Community
Engineering Channel
#MM19IN
Thank you!

More Related Content

Similar to Extension Submission to Marketplace

How to migrate data from Marketpress to Magento by LitExtension
How to migrate data from Marketpress to Magento by LitExtensionHow to migrate data from Marketpress to Magento by LitExtension
How to migrate data from Marketpress to Magento by LitExtensionLitExtension
 
Magento 2 Module in 50 Minutes
Magento 2 Module in 50 MinutesMagento 2 Module in 50 Minutes
Magento 2 Module in 50 MinutesBen Marks
 
Guiding rules for choosing a reliable Magento development partner
Guiding rules for choosing a reliable Magento development partnerGuiding rules for choosing a reliable Magento development partner
Guiding rules for choosing a reliable Magento development partneraheadWorks
 
Magento 2 Inventory Management Extension
Magento 2 Inventory Management ExtensionMagento 2 Inventory Management Extension
Magento 2 Inventory Management ExtensionAppJetty
 
Magento 2 overview. Alan Kent
Magento 2 overview. Alan Kent Magento 2 overview. Alan Kent
Magento 2 overview. Alan Kent MeetMagentoNY2014
 
Upgraded magento migration services and tools
Upgraded magento migration services and toolsUpgraded magento migration services and tools
Upgraded magento migration services and toolsAegis Softtech
 
IDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentIDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentAbid Malik
 
Magento 2 Order Attributes
Magento 2 Order Attributes Magento 2 Order Attributes
Magento 2 Order Attributes MageAnts
 
Backwards Compatibility Developers Guide. #MM17NL
Backwards Compatibility Developers Guide. #MM17NLBackwards Compatibility Developers Guide. #MM17NL
Backwards Compatibility Developers Guide. #MM17NLIgor Miniailo
 
Макс Екатериненко - Meet Magento Ukraine - Magento 2 Overview
Макс Екатериненко - Meet Magento Ukraine - Magento 2 OverviewМакс Екатериненко - Meet Magento Ukraine - Magento 2 Overview
Макс Екатериненко - Meet Magento Ukraine - Magento 2 OverviewAtwix
 
Eradicate Flaky Tests
Eradicate Flaky TestsEradicate Flaky Tests
Eradicate Flaky TestsAnand Bagmar
 
Walmart Magento Integration User Guide - CedCommerce
Walmart Magento Integration User Guide - CedCommerceWalmart Magento Integration User Guide - CedCommerce
Walmart Magento Integration User Guide - CedCommerceCedCommerce
 
Magento 2 Language Translator Extension
Magento 2 Language Translator ExtensionMagento 2 Language Translator Extension
Magento 2 Language Translator ExtensionAppJetty
 
B2C-Commerce-Developer Dumps
B2C-Commerce-Developer DumpsB2C-Commerce-Developer Dumps
B2C-Commerce-Developer Dumpsaddisonkalven
 
Kentico Connection 2014 Boston Upgrade Like a Pro
Kentico Connection 2014 Boston Upgrade Like a ProKentico Connection 2014 Boston Upgrade Like a Pro
Kentico Connection 2014 Boston Upgrade Like a ProBrian McKeiver
 
Your First Magento 2 Module
Your First Magento 2 ModuleYour First Magento 2 Module
Your First Magento 2 ModuleBen Marks
 

Similar to Extension Submission to Marketplace (20)

How to migrate data from Marketpress to Magento by LitExtension
How to migrate data from Marketpress to Magento by LitExtensionHow to migrate data from Marketpress to Magento by LitExtension
How to migrate data from Marketpress to Magento by LitExtension
 
Magento 2 Module in 50 Minutes
Magento 2 Module in 50 MinutesMagento 2 Module in 50 Minutes
Magento 2 Module in 50 Minutes
 
Guiding rules for choosing a reliable Magento development partner
Guiding rules for choosing a reliable Magento development partnerGuiding rules for choosing a reliable Magento development partner
Guiding rules for choosing a reliable Magento development partner
 
BigCommerce Akeneo Connector
BigCommerce Akeneo ConnectorBigCommerce Akeneo Connector
BigCommerce Akeneo Connector
 
Magento 2 Inventory Management Extension
Magento 2 Inventory Management ExtensionMagento 2 Inventory Management Extension
Magento 2 Inventory Management Extension
 
Magento 2 overview. Alan Kent
Magento 2 overview. Alan Kent Magento 2 overview. Alan Kent
Magento 2 overview. Alan Kent
 
Upgraded magento migration services and tools
Upgraded magento migration services and toolsUpgraded magento migration services and tools
Upgraded magento migration services and tools
 
IDE and Toolset For Magento Development
IDE and Toolset For Magento DevelopmentIDE and Toolset For Magento Development
IDE and Toolset For Magento Development
 
Magento 2 Order Attributes
Magento 2 Order Attributes Magento 2 Order Attributes
Magento 2 Order Attributes
 
Backwards Compatibility Developers Guide. #MM17NL
Backwards Compatibility Developers Guide. #MM17NLBackwards Compatibility Developers Guide. #MM17NL
Backwards Compatibility Developers Guide. #MM17NL
 
Open ERP Magento Integration Demo
Open ERP Magento Integration DemoOpen ERP Magento Integration Demo
Open ERP Magento Integration Demo
 
Макс Екатериненко - Meet Magento Ukraine - Magento 2 Overview
Макс Екатериненко - Meet Magento Ukraine - Magento 2 OverviewМакс Екатериненко - Meet Magento Ukraine - Magento 2 Overview
Макс Екатериненко - Meet Magento Ukraine - Magento 2 Overview
 
Magento2 Akeneo Connector
Magento2 Akeneo ConnectorMagento2 Akeneo Connector
Magento2 Akeneo Connector
 
Eradicate Flaky Tests
Eradicate Flaky TestsEradicate Flaky Tests
Eradicate Flaky Tests
 
Walmart Magento Integration User Guide - CedCommerce
Walmart Magento Integration User Guide - CedCommerceWalmart Magento Integration User Guide - CedCommerce
Walmart Magento Integration User Guide - CedCommerce
 
Final (3).pptx
Final (3).pptxFinal (3).pptx
Final (3).pptx
 
Magento 2 Language Translator Extension
Magento 2 Language Translator ExtensionMagento 2 Language Translator Extension
Magento 2 Language Translator Extension
 
B2C-Commerce-Developer Dumps
B2C-Commerce-Developer DumpsB2C-Commerce-Developer Dumps
B2C-Commerce-Developer Dumps
 
Kentico Connection 2014 Boston Upgrade Like a Pro
Kentico Connection 2014 Boston Upgrade Like a ProKentico Connection 2014 Boston Upgrade Like a Pro
Kentico Connection 2014 Boston Upgrade Like a Pro
 
Your First Magento 2 Module
Your First Magento 2 ModuleYour First Magento 2 Module
Your First Magento 2 Module
 

Recently uploaded

Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting DataJhengPantaleon
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docxPoojaSen20
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfakmcokerachita
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️9953056974 Low Rate Call Girls In Saket, Delhi NCR
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13Steve Thomason
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
MENTAL STATUS EXAMINATION format.docx
MENTAL     STATUS EXAMINATION format.docxMENTAL     STATUS EXAMINATION format.docx
MENTAL STATUS EXAMINATION format.docxPoojaSen20
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxheathfieldcps1
 

Recently uploaded (20)

Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data_Math 4-Q4 Week 5.pptx Steps in Collecting Data
_Math 4-Q4 Week 5.pptx Steps in Collecting Data
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docx
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdf
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
call girls in Kamla Market (DELHI) 🔝 >༒9953330565🔝 genuine Escort Service 🔝✔️✔️
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Tilak Nagar Delhi reach out to us at 🔝9953056974🔝
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
MENTAL STATUS EXAMINATION format.docx
MENTAL     STATUS EXAMINATION format.docxMENTAL     STATUS EXAMINATION format.docx
MENTAL STATUS EXAMINATION format.docx
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
The basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptxThe basics of sentences session 2pptx copy.pptx
The basics of sentences session 2pptx copy.pptx
 
9953330565 Low Rate Call Girls In Rohini Delhi NCR
9953330565 Low Rate Call Girls In Rohini  Delhi NCR9953330565 Low Rate Call Girls In Rohini  Delhi NCR
9953330565 Low Rate Call Girls In Rohini Delhi NCR
 

Extension Submission to Marketplace

  • 5. #MM19IN Reasons to Sell Package on Marketplace Centralized space to manage your products Magento users trust marketplace and plugins themes listed on that By being on marketplace you increase brand’s value and its credibility
  • 6. #MM19IN Enter into Marketplace • To submit an extension to Marketplace, you have to be a registered user. So, first, go to marketplace.Magento.com and create an account. • Once you finished the registration, you can move on to a package submission.
  • 8. #MM19IN Two Stages Package will go through Technical Submission Marketing Review
  • 10. #MM19IN Code Review using Tools  Verify Package for Required Files  Coding Standards: Check Code Quality/Syntax  Installation (M2 only): Verify that Product Installs Correctly
  • 11. #MM19IN  Intellectual Property: Check for Plagiarism  Page Caching (M2 only): Verify that Varnish Works Correctly Code Review using Tools
  • 12. #MM19IN Advantage of Code Review using Tools Minimize back and forth process for submission of extension to the marketplace
  • 13. #MM19IN The validation tool to test the package before it is submitted to Magento Marketplace. To download the tool, see the Marketplace Tools GitHub repository. Verify Package for Required Files
  • 14. #MM19IN Required Files All composer.json registration.php Module etc/module.xml Theme theme.xml Language Pack language.xml Metapackage composer.json
  • 15. #MM19IN Usage of validate_m2_package.php validate_m2_package [OPTIONS] <M2 zip file> [<M2 zip file> ...] -h help Prints this usage. -d debug Optional - prints additional debug messages. Verify Package for Required Files
  • 16. #MM19IN silent on success unless the debug option is set ERROR - "<zip file name>": Error message. Errors must be fixed, warnings and notes are purely informational. Can fix any warnings or notes but is not required to. Verify Package for Required Files
  • 18. #MM19IN EQP – Extension Quality Program - a set of rules and sniffs for PHP_CodeSniffer Automatically check your code against some of the common Magento and PHP coding issues Coding Standards: Check Code Quality/Syntax
  • 19. #MM19IN • raw SQL queries; Example : SELECT * from catalog_entity; • Direct class instantiation; Example : $className = MagentoCatalogModelProduct; Coding Standards: Check Code Quality/Syntax
  • 20. #MM19IN • use of PHP superglobals; Example: '$_GET', '$_POST', '$_SESSION', '$_REQUEST', '$_ENV', '$_FILES‘ • use of dangerous functions Example: eval() many more … Coding Standards: Check Code Quality/Syntax
  • 21. #MM19IN https://github.com/Magento/marketplace-eqp $ vendor/bin/phpcs /path/to/your/extension --standard=MEQP2 Example : $ vendor/bin/phpcs /app/code/Wagento/TestModule --standard=MEQP2 Coding Standards: Check Code Quality/Syntax
  • 22. #MM19IN Coding Standards: Check Code Quality/Syntax SEVERITY10 SEVERITY8 SEVERITY 6
  • 23. #MM19IN Coding Standards: Check Code Quality/Syntax TYPE SEVERITY DESCRIPTION MUST BE RESOLVED? Examples - NOT TO BE USED IN CODE Error 10 A critical error with severity level 10 Yes • The opening PHP tag must be the first • Namespace not specified • Use of goto • Use of exit and echo • Use of Super globals • Closing tag should not there • Use of eval()
  • 24. #MM19IN Coding Standards: Check Code Quality/Syntax TYPE SEVERITY DESCRIPTION MUST BE RESOLVED? Examples - NOT TO BE USED IN CODE Warning 8 A severity level 8 warning Developers are encouraged to solve • Long array syntax • Direct Object instantiation • Direct throw of exception • Use of + operator to concate two string • Nesting level of function exceeds 5, refactor function • Use the global keyword
  • 25. #MM19IN Coding Standards: Check Code Quality/Syntax TYPE SEVERITY DESCRIPTION MUST BE RESOLVED? Examples NOT TO BE USED IN CODE Warning 6 A severity level 6 warning Developers are encouraged to solve • Unused Function Parameter • Useless Overriding Method • Commenting Todo Comment Found • Empty Block Detected ELSE • Files Line Length Max Exceeded • Function Call Argument Spacing • Disallow Short Open Tag
  • 26. #MM19IN • Magento Marketplace Technical Review run phpcs command with --severity=10 option. • Example $ vendor/bin/phpcs /path/to/your/extension -- standard=MEQP2 --severity=10 --extensions=php,phtml Coding Standards: Check Code Quality/Syntax
  • 28. #MM19IN • Extension code contains source code from the Magento CE of Magento 1.x or 2.x platforms, the extension must be licensed under Open Source License v. 3.0 • Properly credit to Magento Commerce. Plagiarism
  • 29. #MM19IN • Installs with Composer, • Compiles without errors using the following command: deploy:mode:set production • Works with each version of Magento that is shown as supported in the extension product profile. • Works with each version of PHP that is supported by the Magento version that is shown as supported in the extension product profile. Quality Assurance : Pass Manual QA
  • 30. #MM19IN • Has all functionality that is described in the extension documentation. • Does not crash with unhandled errors. • Does not hang when invalid data is submitted. Quality Assurance : Pass Manual QA
  • 31. #MM19IN • Varnish Test The Production Installation Test (see above) will be done on Magento 2 with Varnish cache • Any unexpected cache misses will be considered a failure • cacheable= false must not be used within the blocks where core Magento is caching the blocks https://devdocs.Magento.com/guides/v2.2/config- guide/varnish/config-varnish.html Varnish Testing
  • 32. #MM19IN • Place store in Developer Mode • Inspect the page headers in your browsers debug network tab. • Look forX-Magento-Cache-Debug: MISS • Refresh the page, it should change to HIT Recommended to check for Product detail page , customer account pages etc Varnish Testing
  • 33. #MM19IN When we add cachable="false" X-Magento-Cache-Debug:MISS X-Magento-Cache-Control:max-age=0, must-revalidate, no-cache, no- store Age: 0 When we remove cacheable="false" X-Magento-Cache-Control:max-age=86400, public, s-maxage=86400 X-Magento-Cache-Debug:HIT X-Magento-Cache-Hits:1 Age:32 Varnish Testing
  • 34. #MM19IN Marketing Review Solve a business problem and deliver rich and unique functionality
  • 35. #MM19IN Marketing Review  Spell-check all text fields and product documentation  Pricing: Complete pricing information  Content: Complete brief & detailed description  Branding: Follow Magento brand and logo guidelines
  • 36. #MM19IN Marketing Review • Your product must have a professional presentation with clear descriptions, images, and screenshots. • The product name should indicate the purpose of the extension or theme. • The product description should be well-written, and provide an overview of the features and benefits. • Use only high-quality screenshots, images, and video to accompany the listing.
  • 37. #MM19IN Contribution Program for EQP Please feel free to contribute new sniffs or any fixes or improvements for the existing ones.
  • 39. #MM19IN Contribution Program for EQP You can get latest updates by slack channel of coding-standards on Magento Community Engineering Channel

Editor's Notes

  1. Enhanced functionality of Magento
  2. Store that brings together merchants and qualified developers of Magento solutions. After Magento closed their Connect, Marketplace became the only platform for selling both Magento 1 and Magento 2 extensions.
  3. Store that brings together merchants and qualified developers of Magento solutions. After Magento closed their Connect, Marketplace became the only platform for selling both Magento 1 and Magento 2 extensions.
  4. Marketplace will ask you to provide some basic information, such as your company type and your role (a merchant or a developer). 
  5. Marketplace will ask you to provide some basic information, such as your company type and your role (a merchant or a developer). 
  6. The tool is silent on success unless the debug option is set. If the tool finds any errors it will report them in the following format to make the errors searchable: ERROR - "<zip file name>": Error message. Errors must be fixed, warnings and notes are purely informational. The user can fix any warnings or notes but is not required to.
  7. The tool is silent on success unless the debug option is set. If the tool finds any errors it will report them in the following format to make the errors searchable: ERROR - "<zip file name>": Error message. Errors must be fixed, warnings and notes are purely informational. The user can fix any warnings or notes but is not required to.
  8. Everyone has their own style of writing code and there’s always a debate which one’s is the correct one or which one’s makes the most sense. For that reason rules are brought that need to be followed that define code standards and enhance source code readability. Code sniffer is a standard or set of rules that applies to source code. It automatically checks for code against some of the common coding issues, irregularities, inconsistencies, errors and identifies them… things like:
  9. All severity 10 errors must be fixed in order to successfully pass Level 1 CodeSniffer checks. During technical review, all submissions are checked to ensure that the code meets Magento standards.
  10. All severity 10 errors must be fixed in order to successfully pass Level 1 CodeSniffer checks. During technical review, all submissions are checked to ensure that the code meets Magento standards.
  11. All severity 10 errors must be fixed in order to successfully pass Level 1 CodeSniffer checks. During technical review, all submissions are checked to ensure that the code meets Magento standards.
  12. All severity 10 errors must be fixed in order to successfully pass Level 1 CodeSniffer checks.
  13. All severity 10 errors must be fixed in order to successfully pass Level 1 CodeSniffer checks. https://github.com/Magento/marketplace-eqp/blob/master/MEQP2/ruleset.xml
  14. This check verifies that the extension installs without error, is configurable (as applicable), and operates as expected. To pass Manual QA, the extension must meet the following requirements:
  15. This check verifies that the extension installs without error, is configurable (as applicable), and operates as expected. To pass Manual QA, the extension must meet the following requirements:
  16. This check verifies that the extension installs without error, is configurable (as applicable), and operates as expected. To pass Manual QA, the extension must meet the following requirements:
  17. Extensions that fail this step will be notified accordingly and will be suspended from Marketplace unless they promptly deliver any fixes required.
  18. Extensions that fail this step will be notified accordingly and will be suspended from Marketplace unless they promptly deliver any fixes required.
  19. devdocs.Magento.com/guides/v2.0/config-guide/varnish/config-varnish.html Extensions that fail this step will be notified accordingly and will be suspended from Marketplace unless they promptly deliver any fixes required.
  20. When you have completed the code you can submit your extension for technical and/or marketing review. The extension is placed in a queue as soon as it is submitted. You will receive confirmation by email, and can track the status of your submission from your Marketplace account. Before submitting an extension or theme for marketing review, conduct your own internal review of the content to make sure that it is ready for publication. Here are a few suggestions:
  21. Your product must have a professional presentation with clear descriptions, images, and screenshots. The product name should indicate the purpose of the extension or theme. The product description should be well-written, and provide an overview of the features and benefits. Use only high-quality screenshots, images, and video to accompany the listing.