- Issue created by @phenaproxima
- πΊπΈUnited States phenaproxima Massachusetts
Honestly...on second thought, we might not need this to be generic at all. It's probably easier to just expose the plugin-specific actions we need, in the modules that provide them.
- Status changed to Needs work
8 months ago 8:47pm 15 March 2024 - Status changed to Needs review
8 months ago 8:55pm 15 March 2024 - πΊπΈUnited States phenaproxima Massachusetts
- Status changed to RTBC
8 months ago 10:31pm 19 March 2024 - π§πͺBelgium wim leers Ghent π§πͺπͺπΊ
Beautiful! π Zero remarks.
- Status changed to Needs work
8 months ago 9:56pm 22 March 2024 - π¬π§United Kingdom alexpott πͺπΊπ
We're not running this test or scanning this code. See .recipes.gitlab-ci.yml - you need to add the directories to the TEST_DIRECTORIES and CODE_DIRECTORIES - also can you move the test into it's own directory in the content_moderation module so that it is separate.
- Status changed to RTBC
8 months ago 2:25am 23 March 2024 - πΊπΈUnited States phenaproxima Massachusetts
Nice catch; fixed.
Since this was not a substantive code change, flipping this back to RTBC.
- π¬π§United Kingdom alexpott πͺπΊπ
I'm wondering something... what happens if a recipe enables content_moderation and uses this plugin in the same recipe - will that work? How does recipe validation work when the action plugin does not exist yet?
- Status changed to Needs work
8 months ago 9:31am 23 March 2024 - π¬π§United Kingdom alexpott πͺπΊπ
Plus we need to convert this to an ConfigAction attribute now
- Status changed to Needs review
8 months ago 10:51am 23 March 2024 - πΊπΈUnited States phenaproxima Massachusetts
Converted to an attribute!
Regarding #11, this is something we added test coverage for in #3423523: Test that recipe runner fails and rolls back if a recipe tries to use a non-existent config action β . The recipe runner will fail because the plugin does not exist.
That said, the plugin will exist the moment the providing module is installed by the recipe. I've changed the test to prove this; it now installs Content Moderation and Workflows, and creates the editorial workflow (copied from the Standard editorial_workflow recipe), before using the config action.
- Status changed to Needs work
8 months ago 5:38pm 23 March 2024 - Status changed to Needs review
8 months ago 6:01pm 23 March 2024 - Status changed to Needs work
8 months ago 10:24pm 23 March 2024 - π¬π§United Kingdom alexpott πͺπΊπ
I've added the new plugin directory to the list of things to be scanned and there are some things to fix.
- πΊπΈUnited States phenaproxima Massachusetts
Come on, this is no fair.
PHPStan is giving me errors like this one, in
AddModeration.php
:32 Method Drupal\content_moderation\Plugin\ConfigAction\AddModeration::create() has parameter $configuration with no value type specified in iterable type array. π‘ See: https://phpstan.org/blog/solving-phpstan-no-value-type-specified-in-iterable-type
This is in reference to a completely standard implementation of ContainerFactoryPluginInterface::create().
What exactly am I supposed to do here?? $configuration is unused, and the interface docs (which I can't change) just specify a type hint of
array
.This feels like too many pointless hoops to jump through.
- π¬π§United Kingdom alexpott πͺπΊπ
@phenaproxima it just goes in the baseline and we forget. I do this that we should comment on the level 9 for core issue to show how disruptive this will be for adding new work to core.
FWIW the phpstan level 9 job has a baseline for you to download with all the errors included - which you can download and commit and then the job will be green.
- Status changed to Needs review
8 months ago 2:52pm 25 March 2024 - πΊπΈUnited States phenaproxima Massachusetts
Fixed what I could, but altered the baseline as well to account for core's non-compliance. Finally we're passing!
- Status changed to RTBC
8 months ago 4:00pm 25 March 2024 - πΊπΈUnited States phenaproxima Massachusetts
Everything in the last couple of days was just coding standards-related; I don't think I made any substantive changes.
- π¬π§United Kingdom alexpott πͺπΊπ
Committed and pushed b4fc09885e2 to 11.x and 20a2005e57e to 10.3.x. Thanks!
-
alexpott β
committed 20a2005e on 10.3.x
Issue #3422821 by phenaproxima, alexpott: Add a config action to add...
-
alexpott β
committed 20a2005e on 10.3.x
- Status changed to Fixed
8 months ago 4:54pm 25 March 2024 -
alexpott β
committed b4fc0988 on 11.x
Issue #3422821 by phenaproxima, alexpott: Add a config action to add...
-
alexpott β
committed b4fc0988 on 11.x
- e3b3e96e committed on patch
Update recipe 10.3.x patch 20a2005e Issue #3422821 by phenaproxima,...
- e3b3e96e committed on patch
- 4856f52a committed on patch
Update recipe 11.x patch b4fc0988 Issue #3422821 by phenaproxima,...
- 4856f52a committed on patch
Automatically closed - issue fixed for 2 weeks with no activity.