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

uninstallation of dhl/shipping-m2 #65

Closed
tobiasolge opened this issue Dec 1, 2023 · 11 comments
Closed

uninstallation of dhl/shipping-m2 #65

tobiasolge opened this issue Dec 1, 2023 · 11 comments

Comments

@tobiasolge
Copy link

Hi,

ho to uninstall dhl/shipping-m2?

We disabled the following modules because of an incompatibility with another module.
magento module:disable Netresearch_ShippingCore Dhl_UnifiedTracking Netresearch_ConfigFields Dhl_ShippingCore Dhl_Paket Netresearch_AdminNotificationFeed Dhl_PaketReturns Netresearch_InteractiveBatchProcessing DeutschePost_Internetmarke Netresearch_ShippingUi PostDirekt_Autocomplete PostDirekt_Core

But there are still cronjobs running (postdirekt_addressfactory_autoprocess_job) which marks offline payment orders as paied, qhich they aren't and creates a shipment.

I tried to uninstall the modules from composer.json as described in the Readme files.
magento module:uninstall --remove-data PostDirekt_Autocomplete
magento module:uninstall --remove-data PostDirekt_Addressfactory
magento module:uninstall --remove-data DeutschePost_Internetmarke
magento module:uninstall --remove-data Dhl_Paket
magento module:uninstall --remove-data Dhl_PaketReturns

this does not work because of dependencies.

Command "remove" failed: dhl/module-carrier-paket-returns is not required in your composer.json and has not been removed

Removal failed, dhl/module-carrier-paket-returns is still present, it may be required by another package. See composer why dhl/module-carrier-paket-returns.

Please assist.

@ngolatka
Copy link

ngolatka commented Dec 1, 2023

Hello @tobiasolge, did you try this command already?

composer remove dhl/shipping-m2

@tobiasolge
Copy link
Author

how come, that there still is a cronjob running?

@tobiasolge
Copy link
Author

and why are orders, that are not paid marked as paid by the cron?

@powli
Copy link
Member

powli commented Dec 12, 2023

@tobiasolge:

Which cron job is running? Also how do you determine the orders being marked as paid?

@tobiasolge
Copy link
Author

tobiasolge commented Dec 12, 2023

@powli
job_code: postdirekt_addressfactory_autoprocess_job
This happened on pay in advance orders. In these cases, we create an invoice manually.
For some orders an invoice was created automatically. The timestamp on the invoice is the same as the finished_at from that cron.

@tobiasolge
Copy link
Author

There seem to be some more problems.
We have the following errors:
Error: SQLSTATE[42S02]: Base table or view not found: 1146 Table 'magento2.nrshipping_order_item' doesn't exist, query was: SELECT main_table.*, extension_attribute_nrshipping_country_of_manufacture.country_of_manufacture AS extension_attribute_nrshipping_country_of_manufacture_country_of_manufacture, extension_attribute_nrshipping_export_description.export_description AS extension_attribute_nrshipping_export_description_export_description, extension_attribute_nrshipping_hs_code.hs_code AS extension_attribute_nrshipping_hs_code_hs_code FROM sales_order_item AS main_table LEFT JOIN nrshipping_order_item AS extension_attribute_nrshipping_country_of_manufacture ON main_table.item_id = extension_attribute_nrshipping_country_of_manufacture.item_id LEFT JOIN nrshipping_order_item AS extension_attribute_nrshipping_export_description ON main_table.item_id = extension_attribute_nrshipping_export_description.item_id LEFT JOIN nrshipping_order_item AS extension_attribute_nrshipping_hs_code ON main_table.item_id = extension_attribute_nrshipping_hs_code.item_id WHERE ((order_id = ''))

@mam08ixo
Copy link
Contributor

Hi @tobiasolge, I am not sure what you are asking for. How to remove a package from a project was already explained before:

composer remove dhl/shipping-m2

Obviously, there is still code in your project that

  • executes cron jobs (none of our cron jobs marks orders as paid by the way, this is not a payment module) and
  • attempts to access database tables that you have removed.

So the first step for you is to remove the module files completely from the project.

Second step is data cleanup. Given you receive that SQL error, I assume you cleaned up the database already. If not, restore a dump or compare the schema files with your database to detect any leftovers. Schema files:

@tobiasolge
Copy link
Author

Hi, yes, but there is still a cronjob running....
job code: postdirekt_addressfactory_autoprocess_job

@mam08ixo
Copy link
Contributor

Then I suggest you find out why it is still running. Something cache? Cron schedule still stored in configuration files/table?

@tobiasolge
Copy link
Author

we do have nothing, that scheduled that cron.

@mam08ixo
Copy link
Contributor

That's good news! When it is not scheduled, then it does not run.

@Sebastian80 Sebastian80 closed this as not planned Won't fix, can't repro, duplicate, stale Jun 3, 2024
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

No branches or pull requests

5 participants