magento2: [2.3.1] Wishlist module shouldn't have a hard dependency on Captcha module

Preconditions (*)

  1. Magento 2.3.1
  2. PHP 7.2.15

Steps to reproduce (*)

  1. Install Magento 2.3.1 using composer
  2. Look at the file vendor/magento/module-wishlist/composer.json

Expected result (*)

  1. Not seeing magento/module-captcha in there
  2. The Wishlist module should be able to work when the captcha module isn’t installed

Actual result (*)

  1. Seeing magento/module-captcha in there
  2. Not sure the wishlist module works without captcha installed, not tested yet.

Discussion

This dependency got introduced in Magento 2.3.1 in https://github.com/magento/magento2/commit/d8eacadc25cd6a98fbaf646ca39c9bb9ebb9f5de#diff-649e244f0c6d1bd88471ebeee385eb6e

We don’t want this hard dependency, because we don’t want to install the default Captcha module of Magento, we have our own module for that and we don’t need two modules providing similar functionality.

Until now, it looks like only the sendfriend module had a hard dependency on the captcha module (this is probably incorrect as well). We don’t need the sendfriend module either, so we also don’t install that, which allowed us to remove the captcha module as well. But we do need the wishlist module so we can no longer remove the captcha module.

I’m not sure if this hard dependency can be removed somehow, it probably won’t be that easy? Maybe the coupling between captcha & wishlist should have been done in a new module instead of adding it to the existing wishlist module?

About this issue

  • Original URL
  • State: open
  • Created 5 years ago
  • Reactions: 4
  • Comments: 18 (4 by maintainers)

Commits related to this issue

Most upvoted comments

Thanks for the effort @Aditya-Prakash-Talluru, but in my opinion this is not enough. I think all references to the Captcha module should be removed from the Wishlist module and moved to new module, called Magento_WishlistCaptcha or something like that (a bit similar to Magento_PaypalCaptcha I think).

The problem is that I don’t know if Adobe will allow such big changes, they might consider it backwards incompatible, but I’m not sure…

@magento I am working on this

@magento I am working on this