peachpiecompiler / peachpie

PeachPie - the PHP compiler and runtime for .NET and .NET Core
https://www.peachpie.io
Apache License 2.0
2.38k stars 203 forks source link

WooCommerece plugin installs and activates with many errors #973

Open azoof-ahmed opened 3 years ago

azoof-ahmed commented 3 years ago

I created an Asp.Net Core 3.1 Project and used the PeachPied.Wordpress.AspNetCore 5.8.0-preview9 for the WordPress Server. WordPress installs flawlessly but WooCommerce Plugin installs with lots of warnings and errors with more at activation. I've tried installing from the plugin store and even manually by copying the files. Both methods gives me the same warnings and errors.

So far I've seen this repository by @diddledani, but it didn't seem to work on the first try. I gave up on looking for a solution since its from 2 years ago.

Errors and Warnings   | PHP5014 | /wp-content/plugins/woocommerce/includes/wc-deprecated-functions.php (726,9): | wc_product_dropdown_categories() expects 1 parameter(s), 4 given -- | -- | -- | --   | PHP5014 | /wp-content/plugins/woocommerce/includes/wc-order-functions.php (1061,2): | remove_filter() expects 3 parameter(s), 4 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/wc-template-functions.php (116,3): | remove_action() expects 3 parameter(s), 4 given   | PHP5022 | /wp-content/plugins/woocommerce/includes/admin/importers/mappings/shopify.php (33,3): | Duplicate array key: 'Variant SKU'.   | PHP5033 | /wp-content/plugins/woocommerce/vendor/automattic/jetpack-autoloader/src/autoload.php (4,14): | Script file 'wp-content/plugins/woocommerce/vendor/automattic/jetpack-autoloader/src/jetpack-autoloader/class-autoloader.php' could not be resolved, the script inclusion is unbound.   | PHP5033 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/vendor/automattic/jetpack-autoloader/src/autoload.php (4,14): | Script file 'wp-content/plugins/woocommerce/packages/woocommerce-blocks/vendor/automattic/jetpack-autoloader/src/jetpack-autoloader/class-autoloader.php' could not be resolved, the script inclusion is unbound.   | PHP5018 | /wp-content/plugins/woocommerce/includes/wc-template-functions.php (3585,3): | Deprecated: Method 'wp_no_robots' has been deprecated. 5.7.0 Use wp_robots_no_robots() instead on 'wp_robots' filter.   | PHP5033 | /wp-content/plugins/woocommerce/packages/woocommerce-admin/vendor/automattic/jetpack-autoloader/src/autoload.php (4,14): | Script file 'wp-content/plugins/woocommerce/packages/woocommerce-admin/vendor/automattic/jetpack-autoloader/src/jetpack-autoloader/class-autoloader.php' could not be resolved, the script inclusion is unbound.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Container.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Definition/DefinitionAggregateInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/ContainerAwareInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Argument/ArgumentResolverInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Definition/DefinitionInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/ContainerAwareTrait.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/ReflectionContainer.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Inflector/Inflector.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Argument/ArgumentResolverTrait.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Inflector/InflectorAggregate.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Argument/ClassName.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Inflector/InflectorAggregateInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Argument/ClassNameInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Inflector/InflectorInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/ServiceProvider/AbstractServiceProvider.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/ServiceProvider/BootableServiceProviderInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Argument/RawArgument.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/ServiceProvider/ServiceProviderAggregate.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Argument/RawArgumentInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/ServiceProvider/ServiceProviderAggregateInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Definition/Definition.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/ServiceProvider/ServiceProviderInterface.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5012 | /wp-content/plugins/woocommerce/lib/packages/League/Container/Definition/DefinitionAggregate.php (1,7): | Declare construct will be ignored, because it is currently not supported by Peachpie.   | PHP5018 | /wp-content/plugins/woocommerce/includes/class-wc-cart.php (1619,18): | Deprecated: Method 'WC_Coupon::is_valid' has been deprecated. 3.2.0 In favor of WC_Discounts->is_coupon_valid.   | PHP5018 | /wp-content/plugins/woocommerce/includes/class-wc-api.php (50,51): | Deprecated: Method 'Automattic\WooCommerce\RestApi\Package::get_version' has been deprecated. since 4.5.0. This tracks WooCommerce version now.   | PHP5018 | /wp-content/plugins/woocommerce/includes/class-wc-api.php (68,51): | Deprecated: Method 'Automattic\WooCommerce\RestApi\Package::get_path' has been deprecated. since 4.5.0. Directly call Automattic\WooCommerce\RestApi\Server::get_path()   | PHP5018 | /wp-content/plugins/woocommerce/includes/class-wc-cart.php (1731,23): | Deprecated: Method 'WC_Coupon::is_valid' has been deprecated. 3.2.0 In favor of WC_Discounts->is_coupon_valid.   | PHP5018 | /wp-content/plugins/woocommerce/includes/class-wc-cart.php (725,20): | Deprecated: Method 'WC_Coupon::is_valid' has been deprecated. 3.2.0 In favor of WC_Discounts->is_coupon_valid.   | PHP5007 | /wp-content/plugins/woocommerce/includes/class-wc-deprecated-action-hooks.php (182,18): | Undefined variable: $item   | PHP5007 | /wp-content/plugins/woocommerce/includes/class-wc-deprecated-action-hooks.php (183,28): | Undefined variable: $order_id   | PHP5007 | /wp-content/plugins/woocommerce/includes/class-wc-deprecated-action-hooks.php (183,39): | Undefined variable: $item_id   | PHP5007 | /wp-content/plugins/woocommerce/includes/class-wc-deprecated-action-hooks.php (183,49): | Undefined variable: $item   | PHP5014 | /wp-content/plugins/woocommerce/includes/class-wc-query.php (419,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/class-wc-regenerate-images-request.php (135,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/class-wc-regenerate-images-request.php (135,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/class-wc-regenerate-images.php (431,3): | remove_action() expects 3 parameter(s), 4 given   | PHP5018 | /wp-content/plugins/woocommerce/includes/admin/class-wc-admin-setup-wizard.php (595,17): | Deprecated: Method 'WC_Admin_Setup_Wizard::tracking_modal' has been deprecated. 4.6.0   | PHP5014 | /wp-content/plugins/woocommerce/includes/class-wc-form-handler.php (857,5): | remove_action() expects 3 parameter(s), 4 given   | PHP5018 | /wp-content/plugins/woocommerce/includes/admin/class-wc-admin-duplicate-product.php (117,97): | Deprecated: Method 'WC_Admin_Duplicate_Product::get_product_to_duplicate' has been deprecated. 3.0.0   | PHP5014 | /wp-content/plugins/woocommerce/includes/export/abstract-wc-csv-exporter.php (504,4): | fputcsv() expects 4 parameter(s), 5 given   | PHP5018 | /wp-content/plugins/woocommerce/includes/legacy/abstract-wc-legacy-product.php (107,21): | Deprecated: Method 'WC_Abstract_Legacy_Product::get_total_stock' has been deprecated. 3.0.0   | PHP5018 | /wp-content/plugins/woocommerce/includes/admin/class-wc-admin-setup-wizard.php (1976,63): | Deprecated: Method 'WC_Admin_Setup_Wizard::get_next_step_link' has been deprecated. 4.6.0   | PHP5007 | /wp-content/plugins/woocommerce/includes/cli/class-wc-cli-tool-command.php (100,60): | Undefined variable: $command_args   | PHP5009 | /wp-content/plugins/woocommerce/includes/legacy/abstract-wc-legacy-product.php (562,10): | Call to undefined method: WC_Abstract_Legacy_Product::sync()   | PHP5033 | /wp-content/plugins/woocommerce/includes/admin/settings/views/class-wc-settings-rest-api.php (11,16): | Script file 'wp-content/plugins/woocommerce/includes/admin/settings/views/class-wc-settings-advanced.php' could not be resolved, the script inclusion is unbound.   | PHP6004 | /wp-content/plugins/woocommerce/includes/log-handlers/class-wc-log-handler-file.php (67,18): | Use of '__destruct' is discouraged. Garbage collection behavior is a subject to change.   | PHP5007 | /wp-content/plugins/woocommerce/vendor/composer/ClassLoader.php (345,58): | Undefined variable: $hit   | PHP5014 | /wp-content/plugins/woocommerce/includes/admin/reports/class-wc-report-customer-list.php (56,47): | esc_html() expects 1 parameter(s), 2 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/shipping/legacy-flat-rate/class-wc-shipping-legacy-flat-rate.php (123,3): | remove_shortcode() expects 1 parameter(s), 2 given   | PHP5018 | /wp-content/plugins/woocommerce/includes/admin/settings/class-wc-settings-page.php (211,23): | Deprecated: Method 'WC_Settings_Page::get_settings' has been deprecated. 5.4.0 Use 'get_settings_for_section' (passing an empty string for default section)   | PHP5018 | /wp-content/plugins/woocommerce/includes/admin/settings/class-wc-settings-page.php (232,23): | Deprecated: Method 'WC_Settings_Page::get_settings' has been deprecated. 5.4.0 Use 'get_settings_for_section' (passing an empty string for default section)   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-orders.php (326,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5018 | /wp-content/plugins/woocommerce/src/Internal/DependencyManagement/AbstractServiceProvider.php (78,23): | Deprecated: Method 'ReflectionParameter::getClass' has been deprecated. Use getType() instead.   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-orders.php (326,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-customers.php (406,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-customers.php (410,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-orders.php (326,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-customers.php (406,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-customers.php (406,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-customers.php (410,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v1/class-wc-api-customers.php (410,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-customers.php (690,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-customers.php (694,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5018 | /wp-content/plugins/woocommerce/includes/legacy/api/class-wc-rest-legacy-products-controller.php (730,21): | Deprecated: Method 'WC_REST_Legacy_Products_Controller::set_product_meta' has been deprecated. 3.0.0   | PHP5018 | /wp-content/plugins/woocommerce/includes/legacy/api/class-wc-rest-legacy-products-controller.php (738,12): | Deprecated: Method 'WC_REST_Legacy_Products_Controller::save_variations_data' has been deprecated. 3.0.0   | PHP5007 | /wp-content/plugins/woocommerce/includes/rest-api/Utilities/ImageAttachment.php (50,108): | Undefined variable: $images   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-customers.php (680,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-customers.php (684,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-orders.php (1213,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/shipping/flat-rate/class-wc-shipping-flat-rate.php (92,3): | remove_shortcode() expects 1 parameter(s), 2 given   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-customers.php (680,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-customers.php (684,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5014 | /wp-content/plugins/woocommerce/includes/rest-api/Controllers/Version1/class-wc-rest-order-notes-v1-controller.php (195,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-orders.php (1258,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-customers.php (690,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-customers.php (694,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-orders.php (1258,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-orders.php (1213,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-orders.php (1213,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-customers.php (680,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-customers.php (684,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5018 | /wp-content/plugins/woocommerce/includes/rest-api/Controllers/Version2/class-wc-rest-products-v2-controller.php (294,56): | Deprecated: Method 'wc_get_min_max_price_meta_query' has been deprecated. 3.6.0   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-customers.php (690,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5025 | /wp-content/plugins/woocommerce/includes/legacy/api/v2/class-wc-api-customers.php (694,36): | Call to 'sprintf()' expects 4 argument(s), 2 given.   | PHP5014 | /wp-content/plugins/woocommerce/includes/legacy/api/v3/class-wc-api-orders.php (1258,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5018 | /wp-content/plugins/woocommerce/packages/action-scheduler/classes/WP_CLI/ActionScheduler_WPCLI_QueueRunner.php (194,11): | Deprecated: Method 'ActionScheduler_WPCLI_QueueRunner::stop_the_insanity' has been deprecated. 3.0.0   | PHP5014 | /wp-content/plugins/woocommerce/includes/rest-api/Controllers/Version2/class-wc-rest-order-notes-v2-controller.php (66,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5018 | /wp-content/plugins/woocommerce/includes/rest-api/Controllers/Version3/class-wc-rest-product-variations-controller.php (814,56): | Deprecated: Method 'wc_get_min_max_price_meta_query' has been deprecated. 3.6.0   | PHP5014 | /wp-content/plugins/woocommerce/packages/woocommerce-admin/src/RemoteInboxNotifications/DataSourcePoller.php (52,30): | Automattic\WooCommerce\Admin\RemoteInboxNotifications\DataSourcePoller::read_data_source() expects 1 parameter(s), 2 given   | PHP5018 | /wp-content/plugins/woocommerce/includes/rest-api/Controllers/Version3/class-wc-rest-products-controller.php (178,56): | Deprecated: Method 'wc_get_min_max_price_meta_query' has been deprecated. 3.6.0   | PHP5007 | /wp-content/plugins/woocommerce/packages/woocommerce-admin/vendor/composer/ClassLoader.php (369,58): | Undefined variable: $hit   | PHP5015 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/Integrations/IntegrationRegistry.php (98,4): | _doing_it_wrong() expects at least 3 parameter(s), 2 given   | PHP5007 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/vendor/composer/ClassLoader.php (369,58): | Undefined variable: $hit   | PHP5014 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/BlockTypes/Checkout.php (222,3): | remove_filter() expects 3 parameter(s), 4 given   | PHP5015 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/Integrations/IntegrationRegistry.php (35,4): | _doing_it_wrong() expects at least 3 parameter(s), 2 given   | PHP5015 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/Integrations/IntegrationRegistry.php (67,4): | _doing_it_wrong() expects at least 3 parameter(s), 2 given   | PHP5018 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/StoreApi/Utilities/CartController.php (805,19): | Deprecated: Method 'WC_Coupon::is_valid' has been deprecated. 3.2.0 In favor of WC_Discounts->is_coupon_valid.   | PHP5018 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/StoreApi/Utilities/CartController.php (861,19): | Deprecated: Method 'WC_Coupon::is_valid' has been deprecated. 3.2.0 In favor of WC_Discounts->is_coupon_valid.   | PHP5018 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/StoreApi/Routes/CartRemoveCoupon.php (58,59): | Deprecated: Method 'WC_Coupon::is_valid' has been deprecated. 3.2.0 In favor of WC_Discounts->is_coupon_valid.   | PHP5007 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/StoreApi/Schemas/ProductReviewSchema.php (164,47): | Undefined variable: $request   | PHP5007 | /wp-content/plugins/woocommerce/packages/woocommerce-admin/src/API/Reports/Stock/Stats/Controller.php (74,83): | Undefined variable: $product   | PHP5014 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/src/Domain/Services/CreateAccount.php (56,5): | remove_action() expects 3 parameter(s), 4 given   | PHP4044 | /wp-content/plugins/woocommerce/vendor/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php (29,41): | Type name 'Composer\Plugin\PluginInterface' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php (29,58): | Type name 'Composer\EventDispatcher\EventSubscriberInterface' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/CssSelectorConverterTest.php (17,40): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Parser/ParserTest.php (21,26): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Parser/ReaderTest.php (17,26): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Node/SpecificityTest.php (17,31): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Parser/TokenStreamTest.php (18,31): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/XPath/TranslatorTest.php (18,30): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Node/AbstractNodeTest.php (17,41): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/vendor/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php (29,41): | Type name 'Composer\Plugin\PluginInterface' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/vendor/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php (29,58): | Type name 'Composer\EventDispatcher\EventSubscriberInterface' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/packages/woocommerce-admin/vendor/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php (29,41): | Type name 'Composer\Plugin\PluginInterface' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/packages/woocommerce-admin/vendor/automattic/jetpack-autoloader/src/CustomAutoloaderPlugin.php (29,58): | Type name 'Composer\EventDispatcher\EventSubscriberInterface' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/composer/installers/src/Composer/Installers/Installer.php (14,25): | Type name 'Composer\Installer\LibraryInstaller' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/composer/installers/src/Composer/Installers/Plugin.php (9,25): | Type name 'Composer\Plugin\PluginInterface' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Parser/Shortcut/ClassParserTest.php (21,31): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Parser/Shortcut/ElementParserTest.php (21,33): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Parser/Shortcut/EmptyStringParserTest.php (21,37): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Parser/Shortcut/HashParserTest.php (21,30): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/vendor/symfony/css-selector/Tests/Parser/Handler/AbstractHandlerTest.php (22,44): | Type name 'PHPUnit\Framework\TestCase' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/packages/woocommerce-admin/vendor/composer/installers/src/Composer/Installers/Installer.php (14,25): | Type name 'Composer\Installer\LibraryInstaller' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/packages/woocommerce-admin/vendor/composer/installers/src/Composer/Installers/Plugin.php (9,25): | Type name 'Composer\Plugin\PluginInterface' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/vendor/composer/installers/src/Composer/Installers/Installer.php (14,25): | Type name 'Composer\Installer\LibraryInstaller' could not be resolved.   | PHP4044 | /wp-content/plugins/woocommerce/packages/woocommerce-blocks/vendor/composer/installers/src/Composer/Installers/Plugin.php (9,25): | Type name 'Composer\Plugin\PluginInterface' could not be resolved.
jakubmisek commented 3 years ago

Hi, thank you for reporting the issue.

The errors are described at https://docs.peachpie.io/php/diagnostics/

Basically, the code contains references to classes (PHPUnit, Composer API) that are not there. So the the files needs to be excluded (for example tests). WooCommerce is not officially supported; the current workaround is to copy woocommerce to the plugins manually, and delete those unnecessary files.

azoof-ahmed commented 3 years ago

I'm new to Peachpie platform and not exactly an expert on WordPress either for that matter. Why are these classes missing? are they going to be added in the future or are they not part of PHP or WordPress?

Also does the method of removing missing classes result in the plugins not working? if they are missing in Peachpie does that mean removing these is safe?

In any case, I'll attempt to remove the missing classes and post the result here

azoof-ahmed commented 3 years ago

I attempted the the WordPress Plugin Guide and came up with this project structure.

Capture

The Server project is an ASP .Net Core empty project with the PeachPied.WordPress.AspNetCore 5.8.0-preview10 and created according to the ASP.NET CORE with WordPress Guide

The WooCommerce plugin is installed, however activation fails with the error "Plugin could not be activated because it triggered a fatal error." and no other details

the output ASP.NET Core Web Server logs showed: "info: PHP[0] Undefined property: wpdb::$error"

this error seems to be logged constantly even when the server is idling

Any idea what this could be?

jakubmisek commented 3 years ago

The wpdb::$error warning is a notice that should not be output, but PeachPie simply does it because of some internal behavior;

azoof-ahmed commented 3 years ago

what about the Plugin installation error? 🤔

jakubmisek commented 3 years ago

@Azuf in the first message?

The errors are described at https://docs.peachpie.io/php/diagnostics/

Basically, the code contains references to classes (PHPUnit, Composer API) that are not there. So the files need to be excluded (for example tests). WooCommerce is not officially supported; the current workaround is to copy woocommerce to the plugins manually and delete those unnecessary files.

azoof-ahmed commented 3 years ago

No not that issue, sorry I wasnt being very specific. You already mentioned that and I actually removed those files.

its from the comment above about the new attempt:

The WooCommerce plugin is installed, however activation fails with the error "Plugin could not be activated because it triggered a fatal error." and no other details

when I attempted to activate after installing from the WordPress plugins page, I did not get this error message. But when I attempt to activate after copying the plugin files into the project it shows the "fatal error" message with no extra details as to what caused it.