Problem/Motivation
In #3477520: Add support for PHP attributes for EncryptionMethod plugins, we added an attribute class. However, I didn't realize that as described in the change record, the attribute class actually needs to be specified in EncryptionMethodManager or it won't be picked up.
However, making this change (I think) requires Drupal 10.2 or higher, which means that to adopt this, the module has to end support for lots of older versions of Drupal.
So I'm going to add this MR, but set it to "postponed" until the module is ready to move to 10.2+.
UPDATE: Not providing an attribute is now deprecated in Drupal 11.2, and is a requirement for Drupal 12: https://www.drupal.org/node/3395582
Issue fork encrypt-3484254
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
ptmkenny commentedComment #4
ptmkenny commentedComment #5
ptmkenny commentedDrupal 12 is on the way.
Comment #7
alexpottLet's convert \Drupal\encrypt_test\Plugin\EncryptionMethod\AsymmetricalEncryptionMethod and \Drupal\encrypt_test\Plugin\EncryptionMethod\ConfigTestEncryptionMethod to prove that attributes are actually working. We can leave \Drupal\encrypt_test\Plugin\EncryptionMethod\TestEncryptionMethod will the annotation to prove we've not broken that.
Comment #8
ptmkenny commented@alexpott Made the conversion as you requested, and added a note to the plugin that we will keep using annotations to not convert it until we drop annotations support.
Comment #9
alexpottThis looks great.
Comment #11
alexpott