MultiSafepay / magento2

MultiSafepay plugin for Magento 2
Open Software License 3.0
18 stars 8 forks source link

Inconsistent inventory reservations when using second chance payment #28

Closed JeroenVanLeusden closed 2 years ago

JeroenVanLeusden commented 2 years ago

To Reproduce

  1. Set Pending Payment Order Status configuration to Pending Payment.
  2. Create order and close screen on payment page, order is now placed in pending payment status.
  3. Set Pending Payment Order Lifetime (minutes) to one minute.
  4. Run cronjob sales_clean_orders.
  5. Run cronjob inventory_cleanup_reservations.
  6. Pay order using second change payment.
  7. Ship order.

Expected behavior Running cronjob inventory_cleanup_reservations should now delete all order related reservations since order is complete. We should check if order placed reservations exist and add them if not when using second change payment.

Actual behavior Running cronjob inventory_cleanup_reservations won't delete the shipment reservations because order placed and order canceled reservations are already delete. We can now oversell this product.

vinodsowdagar commented 2 years ago

Hi @JeroenVanLeusden ,

Thank you for the report. I have created a backlog item to look into this one.

Could you provide some more information in the meantime about your environment?

As soon as i have more information about the status of our investigation, i will let you know.

JeroenVanLeusden commented 2 years ago

Magento Open Source v2.4.3 MultiSafepay version: 2.13.0 All MultiSafepay payment modules are enabled.

vinodsowdagar commented 2 years ago

Hi @JeroenVanLeusden ,

We have investigated this issue and we can unfortunately not reproduce it on a core Magento environment with sample data installed. We have tried versions 2.4.1 and 2.4.3, in both cases the related reservations for a completed order are deleted after running the cronjob. We therefore think the issue lies with perhaps some different settings or inconsistency/incompatibility with third party modules. But we would need more information to continue investigating.

Can you download the MultiSafepay logs and send it to integration@multisafepay.com so we can investigate this further? You can add a link to this issue so my colleagues will know I am already looking into this and forward it to me.

More information about how to download the logs we need: https://docs.multisafepay.com/magento-2/downloading-logs/

vinodsowdagar commented 2 years ago

I am closing this issue due to it either already being picked up through e-mail, or due to being inactive for a long time.