Skip to content

Magento 2.2.5 compatibility #55

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

Merged
merged 26 commits into from
Dec 4, 2018
Merged

Magento 2.2.5 compatibility #55

merged 26 commits into from
Dec 4, 2018

Conversation

avstudnitz
Copy link
Contributor

Category product indexing changed in Magento 2.2, it uses one index table per
store now. We are using that now after checking for the Magento version.

category product indexing change in Magento 2.2, it uses one index table per
store now. We are using that now after checking for the Magento version.
@avstudnitz avstudnitz requested a review from schmengler August 16, 2018 11:05
… index

It has changed in Magento 2.2.5, so the check for the version (>= 2.2)
was not correct. See https://twitter.com/sergeivaschenko/status/1032926575195574274.
@avstudnitz avstudnitz changed the title 2.2 compatibility Magento 2.2.5 compatibility Aug 27, 2018
public function __construct(
Context $context,
ProductMetadataInterface $productMetadata,
?string $connectionName = null
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nullable types (?string) were introduced in PHP 7.1, using this signature will bump the minimum version from 7.0 to 7.1 for both, Magento 2.1 and Magento 2.2. We should be careful with this.

we are using the object manager because the class should not appear
in the constructor as it doesn't exist before Magento 2.2.5
Asynchronous indexing failed because the area code was set to "crontab" instead of "frontend".
@avstudnitz
Copy link
Contributor Author

One more bug fix was added to this PR. Async indexing failed because of the wrong area code, so we are emulating the frontend area now for indexing.

avstudnitz and others added 2 commits September 21, 2018 08:09
the catalog_product_entity_* tables use row_id instead of entity_id as its primary key.
@schmengler
Copy link
Contributor

@avstudnitz I updated the unit tests for area code emulation. they also reported that setForceFrontend() for URL generation was called twice, so I removed the redundant calls

@schmengler schmengler force-pushed the 2.2-compatibility branch 9 times, most recently from 9ba94c4 to 0d7d4f5 Compare October 10, 2018 09:18
@schmengler schmengler force-pushed the 2.2-compatibility branch 8 times, most recently from 64dcd09 to 0a61982 Compare October 10, 2018 10:27
NOTE: Tests were failing in Magento 2.2, PHP 7.0 compatibility is not guaranteed anymore
@schmengler
Copy link
Contributor

Wercker configuration has been updated to work with current Magento 2.1 and 2.2 versions.
There is still an issue with 2.2: integration tests seem to run into an endless loop at one point

@schmengler
Copy link
Contributor

It occurs in several tests that use product fixtures, possibly related to tddwizard/magento2-fixtures#13

Otherwise we get this error:

User Error: DDL statements are not allowed in transactions in /var/www/magento/vendor/magento/framework/DB/Adapter/Pdo/Mysql.php:504.
@avstudnitz avstudnitz merged commit 4d8c8f8 into develop Dec 4, 2018
@avstudnitz avstudnitz deleted the 2.2-compatibility branch December 4, 2018 10:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants