Convert the Standard install profile into a set of recipes

Created on 29 January 2024, 5 months ago
Updated 5 April 2024, 3 months ago

Problem/Motivation

NOTE: This issue supersedes #3301370: Model core's standard install profile as recipes . Its issue fork got all bungled up and is not usable. Since there can only be one issue fork per issue, @alexpott and I decided to open a new issue where we could continue the work from a clean state. And now, back to our regularly scheduled issue summary:

Recipes are conceived as composable, with any given recipe often requiring a chain of other recipes. But there's little practical sense as yet of just how this would work, or of what recommended patterns might be.

Proposed resolution

Let's "rebuild" the Standard install profile as a set of recipes!

There still needs to be an install profile, so but let's begin with Minimal. From there, let's create a set of recipes that are composed together into a new recipe, called Standard. If the Standard recipe is applied, then you should get exactly the same site that you would if you just installed the Standard profile.

We'll want the following test coverage:

  • If you install Minimal, then apply the Standard recipe, all the same expectations as \Drupal\Tests\standard\Functional\StandardTest should pass.
  • Each individual recipe that makes up the Standard recipe should be able to be independently applied, successfully, on top of the Minimal profile.
  • For each individual recipe, each piece of config in it should have its config dependencies fulfilled either by other config in the same recipe, or some config elsewhere in that recipe's dependency tree. This, happily, is proven by the previous test.

There are some things that Standard does, which are currently beyond the capabilities of the recipe system:

  1. Default Shortcut set can not be created. See https://git.drupalcode.org/project/distributions_recipes/-/merge_request... → follow-up: #3418706: [PP-1] Populate the default shortcut set
  2. Can not have menu links similar to standard.links.menu.yml. See https://git.drupalcode.org/project/distributions_recipes/-/merge_request... → follow-up: ⚠️TBD⚠️
  3. Can not assign user 1 the "administrator" role. See https://git.drupalcode.org/project/distributions_recipes/-/merge_request... → follow-up: #3418704: Assign user 1 the "administrator" role. — but probably does not need to be fixed, hence it's already closed
  4. Can not set Contact feedback form recipients. → follow-up: #3303126: Getting user input during / before applying a recipe

There are also certain parts of Standard which aren't installed by Standard itself -- for example, all of its media types are only installed if the Media module is installed. Since recipes don't have the concept of "optional config", Standard's media types, along with the Editorial workflow, should be converted to recipes as well, but they not be amongst the sub-recipes installed by the standard recipe.

What needs to be decided and can be done in follow-ups:

What recipes make up Standard-the-Recipe, and why?

In general, each recipe in Standard aims to provide something complete, tangible, and at least somewhat useful. So if you install any given recipe from Standard, you should end up with something new on your site that is ready to use. The following recipes fall into that category:

  • basic_block_type
  • article_content_type
  • page_content_type
  • feedback_contact_form
  • basic_html_format_editor
  • full_html_format_editor
  • editorial_workflow
  • image_media_type
  • document_media_type
  • local_video_media_type
  • remote_video_media_type
  • audio_media_type
  • standard_responsive_images
  • tags_taxonomy

A couple of the recipes are there to enhance something created by another recipe. Again, the end goal is something tangible and useful, but not necessarily "new". article_tags and article_comment fall into this category.

A few of the recipes are more aimed at establishing common-sense defaults and best practices. Their aim is "set it and forget it":

  • core_recommended_performance
  • core_recommended_maintenance
  • core_recommended_admin_theme
  • core_recommended_front_end_theme

Two recipes are more special-case:

  • comment_base provides basic underlying infrastructure for adding comments to content. We could fold this into article_comment, but I can definitely see a case for having "all the infrastructure for comments, not attached to anything" as a useful "API-only" recipe that would be useful to other recipes in the wild. Therefore, I think keeping this as its own lower-level recipe makes sense.
  • restricted_html_format doesn't seem to fit anywhere else. It feels like another one that might be handy for building on top of, but is very low-key as shipped.

You may happily refer to #3301370: Model core's standard install profile as recipes as needed for prior art and discussion.

Remaining tasks

  1. Build out the recipe tree I've just described.
  2. Add the requested test coverage.
  3. Manually test.
  4. Commit!

User interface changes

None.

API changes

Should be none. If any are needed, they should be filed in blocking or follow-up issues.

Data model changes

None anticipated.

📌 Task
Status

Fixed

Version

11.0

Component

Code

Created by

🇺🇸United States phenaproxima Massachusetts

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @phenaproxima
  • 🇬🇧United Kingdom alexpott 🇪🇺🌍
  • 🇺🇸United States thejimbirch Cape Cod, Massachusetts
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺
  • 🇺🇸United States phenaproxima Massachusetts

    Welp, just as I submitted this issue, @alexpott gave me permission to assign credit. So, transferring credit from #3301370: Model core's standard install profile as recipes .

  • 🇺🇸United States phenaproxima Massachusetts
  • Merge request !70Convert the Standard profile to recipes → (Open) created by phenaproxima
  • Pipeline finished with Failed
    5 months ago
    Total: 156s
    #84363
  • Status changed to Needs work 5 months ago
  • 🇺🇸United States phenaproxima Massachusetts

    Test failures ahoy!

  • 🇺🇸United States phenaproxima Massachusetts

    I have a sneaking suspicion that one of the tests (StandardRecipeTest) is failing due to the config ordering bug I described in #3416287: ConfigConfigurator should be insensitive to key order when comparing active config to recipe config .

    Since I'm not certain that's the cause, I'm not going to explicitly call it a blocking issue...at least, not yet. But I'm linking it as a related one.

  • Pipeline finished with Failed
    5 months ago
    Total: 149s
    #84688
  • Pipeline finished with Canceled
    5 months ago
    Total: 35s
    #84743
  • Pipeline finished with Failed
    5 months ago
    Total: 144s
    #84744
  • 🇮🇳India narendraR Jaipur, India

    Re #12, Test failure is due to change in recipients email in tests from admin@example.com to simpletest@example.com. How can I fix this?

    Also I have added test coverage as per https://www.drupal.org/project/distributions_recipes/issues/3301370#comm...

  • 🇺🇸United States phenaproxima Massachusetts

    Ah, I see what you mean, @narendraR; the Empty profile is creating the feedback contact form one way, and then the feedback_contact_form recipe is trying to fully replace it.

    I think what I would do in this case is remove the contact form, and the code related to it, from the Empty profile entirely. That stuff only seems to be there to emulate Standard, but frankly that contradicts the purpose of the Empty profile. :)

    The real problem here is that when the feedback_contact_form recipe is applied, it needs to be able to ask the user for the recipients (or at least, it needs to be able to extrapolate it from somewhere). So to really properly solve this, we should fix #3303126: Getting user input during / before applying a recipe , but that's a job for another time.

    What would be even better is if the feedback_contact_form recipe could read the value of the system.site:mail value and automatically copy it to the contact form while it was being applied! But that's currently beyond the capabilities of the recipe system.

    I'll open a follow-up issue to at least raise that as a possible feature, since that's the kind of thing recipe authors will likely need from time to time.

  • 🇺🇸United States phenaproxima Massachusetts

    Okay, I updated #3303126-6: Getting user input during / before applying a recipe with our use case. We probably don't need a whole new follow-up, IMHO, since this problem falls into the scope of "collecting input while applying a recipe".

  • 🇺🇸United States thejimbirch Cape Cod, Massachusetts

    Re: #14, I had created the empty profile to have no configuration at all. Investigating what made its way in there.

  • 🇺🇸United States thejimbirch Cape Cod, Massachusetts

    Ah, I see that functionality that cannot be currently done in recipes is being configured in the empty profile.

    I had called some of that out in https://www.drupal.org/project/distributions_recipes/issues/3301370#comm...

    I suggest that rather than state that only Install Profiles can do these things, that we wait until we do everything we can using recipes, and then figure out how to do the remaining items. Some of those items may bring to light additional config actions we need, or be possible with functionality on the roadmap like "default content".

    I'd rather for now we leave the empty profile empty, to be used as an unadulterated clean slate for applying recipes.

  • Pipeline finished with Failed
    5 months ago
    Total: 152s
    #85263
  • Pipeline finished with Failed
    5 months ago
    Total: 198s
    #85272
  • Pipeline finished with Success
    5 months ago
    Total: 203s
    #85400
  • 🇮🇳India narendraR Jaipur, India

    Re #17, I agree with your point, but did it here in MR so that we can plan some action and then remove them. Also it seems to me that the points which you raised in https://www.drupal.org/project/distributions_recipes/issues/3301370#comm... are the only action items to make this recipe identical to standard profile.

  • 🇺🇸United States thejimbirch Cape Cod, Massachusetts

    Makes sense, thanks @narendraR!

  • Pipeline finished with Failed
    5 months ago
    Total: 236s
    #85827
  • 🇮🇳India narendraR Jaipur, India

    I copied StandardTest.php code into StandardRecipeTest.php to check how much it works.
    It basically failed at 2 points:

    • Validating contact feedback form Recipient. We have a separate issue for this.
    • Not sure why installing responsive_image and content_moderation module through service does not worked. Added @todo for this.
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    #20:

    1. That other issue is #3303126: Getting user input during / before applying a recipe , right?
    2. +1 for debugging those 2 problems here; that might lead to a new interesting insight into something Recipes is currently lacking! 😄

    Exciting to see that we're already so close to have StandardRecipeTest passing! 🤩👏

  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺
    1. I hope this has not been discussed previously 😅 If it has been, we should document the rationale in the issue summary.

      Why do recipe names start with "the subjective use case label" rather than "the objective thing"?

      Is it because then it becomes harder to spot the connection between the article_* recipes? 🤔

    2. Related: why even have article_comment + article_content_type + article_tags? Why not just article? Articles have comments and tags, period. If you don't want that, use a different recipe. It feels like unnecessary granularity to me.

      Heck, we could go with standard_article. And then there could be more opinionated variants of "articles" in other recipes provided by contrib?

  • Pipeline finished with Failed
    5 months ago
    Total: 204s
    #85975
  • 🇮🇳India narendraR Jaipur, India

    Re #21.1, the reason is #13. I am not sure why but the value of recipients email is not changing from admin@example.com to simpletest@example.com

  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    #23: Are you saying that we named recipes this particular way to ensure a particular execution order of the recipes? 😰

  • 🇮🇳India narendraR Jaipur, India

    Re #24, No. I am saying this in reference to #20.

    Validating contact feedback form Recipient. We have a separate issue for this.
  • Pipeline finished with Failed
    5 months ago
    Total: 241s
    #86238
  • Pipeline finished with Failed
    5 months ago
    Total: 197s
    #86259
  • 🇺🇸United States thejimbirch Cape Cod, Massachusetts

    Re #22

    1.

    Why do recipe names start with "the subjective use case label" rather than "the objective thing"?

    As part of https://www.drupal.org/project/distributions_recipes/issues/3284777 , documentation was added to the 1.0.x branch. The naming convention is peppered throughout the documentation, but the definition of it is in this doc: https://git.drupalcode.org/project/distributions_recipes/-/blob/1.0.x/do...

    I do agree with @wimleers though, I like bundle_uniquename better rather than uniquename_bundle.

    Should we propose a different naming convention and update the documentation?

    2.

    Related: why even have article_comment + article_content_type + article_tags? Why not just article? Articles have comments and tags, period. If you don't want that, use a different recipe. It feels like unnecessary granularity to me.

    Heck, we could go with standard_article. And then there could be more opinionated variants of "articles" in other recipes provided by contrib?

    To make it as composable and reusable as possible.

    Articles have comments and tags, period.

    Not in any Drupal site I have built in 11 years. Most articles we build do not have comments, and have more specific taxonomy vocabularies like Topics, Category, Subject.

    I believe this may have been a norm in Drupal 6 days of the web, and we should still support it in a composed recipe like standard_article (or article_standard).

    But to make it usable, and extendable by all, it would be good to have the stack of

    article_comment
    article_content_type
    article_tags

    So I could create my own deliverable using the pieces.

  • Pipeline finished with Failed
    5 months ago
    Total: 172s
    #86586
  • Pipeline finished with Failed
    5 months ago
    Total: 183s
    #86593
  • Pipeline finished with Failed
    5 months ago
    Total: 262s
    #86660
  • Pipeline finished with Failed
    5 months ago
    Total: 246s
    #86891
  • 🇮🇳India narendraR Jaipur, India

    Re #20,

    I have found the reason for these 2 test failures.

    Validating contact feedback form Recipient.

    This is because standard.profile file's hook_form_FORM_ID_alter changes recipient's email.

    Not sure why installing responsive_image and content_moderation module through service does not worked.

    These is because tested configuration files exists in standard profile's config folder and only enabling module without standard profile will not help. Recipes do have these files and hence it worked.

    Now as we know the reasons for test failures in StandardRecipeTest.php, what else can be done here.

  • Pipeline finished with Failed
    5 months ago
    Total: 223s
    #86922
  • Pipeline finished with Failed
    5 months ago
    #86929
  • Pipeline finished with Failed
    5 months ago
    Total: 273s
    #86936
  • Pipeline finished with Failed
    5 months ago
    Total: 146s
    #86937
  • Pipeline finished with Failed
    5 months ago
    Total: 233s
    #86938
  • Pipeline finished with Failed
    5 months ago
    Total: 365s
    #86939
  • Pipeline finished with Canceled
    5 months ago
    Total: 301s
    #86945
  • Pipeline finished with Failed
    5 months ago
    Total: 388s
    #86947
  • Pipeline finished with Failed
    5 months ago
    Total: 232s
    #87650
  • Pipeline finished with Failed
    5 months ago
    Total: 340s
    #87744
  • Pipeline finished with Failed
    5 months ago
    Total: 234s
    #87779
  • Pipeline finished with Success
    5 months ago
    Total: 388s
    #87807
  • Pipeline finished with Success
    5 months ago
    Total: 358s
    #87810
  • Pipeline finished with Failed
    5 months ago
    Total: 140s
    #87814
  • 🇮🇳India narendraR Jaipur, India
  • Pipeline finished with Failed
    5 months ago
    Total: 258s
    #88178
  • Pipeline finished with Success
    5 months ago
    Total: 476s
    #88649
  • Status changed to Needs review 5 months ago
  • 🇮🇳India narendraR Jaipur, India

    All feedback addressed/answered, tests passing, IS updated.

  • Status changed to Needs work 5 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    Nice progress here! Some questions on the MR :)

  • 🇺🇸United States phenaproxima Massachusetts
  • Pipeline finished with Success
    5 months ago
    Total: 502s
    #88856
  • Pipeline finished with Success
    5 months ago
    Total: 633s
    #88975
  • Pipeline finished with Canceled
    5 months ago
    #89013
  • Pipeline finished with Canceled
    5 months ago
    Total: 159s
    #89016
  • Pipeline finished with Canceled
    5 months ago
    Total: 214s
    #89019
  • Pipeline finished with Canceled
    5 months ago
    Total: 388s
    #89023
  • Pipeline finished with Success
    5 months ago
    #89027
  • Pipeline finished with Success
    5 months ago
    Total: 586s
    #89037
  • Pipeline finished with Failed
    5 months ago
    Total: 158s
    #89053
  • Pipeline finished with Failed
    5 months ago
    Total: 340s
    #89054
  • Pipeline finished with Failed
    5 months ago
    Total: 558s
    #89056
  • Pipeline finished with Failed
    5 months ago
    Total: 187s
    #89059
  • Pipeline finished with Failed
    5 months ago
    Total: 359s
    #89060
  • Pipeline finished with Failed
    5 months ago
    Total: 148s
    #89064
  • Pipeline finished with Failed
    5 months ago
    Total: 595s
    #89065
  • Pipeline finished with Failed
    5 months ago
    Total: 480s
    #89126
  • Pipeline finished with Failed
    5 months ago
    Total: 479s
    #89129
  • Pipeline finished with Failed
    5 months ago
    Total: 496s
    #89530
  • Pipeline finished with Success
    5 months ago
    Total: 495s
    #89573
  • Pipeline finished with Success
    5 months ago
    Total: 453s
    #89758
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    Let's please document the rationale behind the current recipes that …/standard/recipe.yml depends upon.

    That information will be crucial in eventually landing this in Drupal core. People will nitpick this apart and question why these particular recipes were created (because there is no objectively optimal or best choice). If that happens in 1 year from today, none of us will remember those choices.

  • Pipeline finished with Canceled
    5 months ago
    Total: 41s
    #90747
  • Pipeline finished with Success
    5 months ago
    Total: 517s
    #90749
  • 🇺🇸United States phenaproxima Massachusetts
  • Pipeline finished with Failed
    5 months ago
    Total: 522s
    #90798
  • Pipeline finished with Failed
    5 months ago
    Total: 519s
    #90805
  • 🇺🇸United States phenaproxima Massachusetts
  • 🇺🇸United States phenaproxima Massachusetts

    Re #32, I have updated the issue summary to try and explain the rationale for these recipes as architected.

  • 🇺🇸United States phenaproxima Massachusetts

    Whoops, HTML error.

  • 🇺🇸United States phenaproxima Massachusetts
  • Pipeline finished with Success
    5 months ago
    Total: 356s
    #90849
  • Pipeline finished with Canceled
    5 months ago
    Total: 64s
    #90854
  • Pipeline finished with Failed
    5 months ago
    Total: 310s
    #90855
  • 🇺🇸United States phenaproxima Massachusetts
  • 🇺🇸United States phenaproxima Massachusetts
  • Pipeline finished with Canceled
    5 months ago
    #90858
  • Pipeline finished with Success
    5 months ago
    Total: 264s
    #90859
  • Pipeline finished with Success
    5 months ago
    Total: 290s
    #90866
  • 🇺🇸United States phenaproxima Massachusetts
  • Status changed to Needs review 5 months ago
  • 🇺🇸United States phenaproxima Massachusetts

    I think I'm pretty happy with the way this looks.

    All tests are passing, and the issue summary is up to date. I think we're ready for review.

  • Status changed to Needs work 4 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    Read the entire issue summary prior to re-reviewing the entire merge request. Thanks for the excellent issue summary! 😊🙏 This is definitely going to help Recipes land in core too, because we'll hopefully be able to copy/paste this verbatim for the future core inclusion issue 👍

    Thoughts:

    1. I made a few minor edits to the issue summary to improve clarity. Can you check and confirm they're correct, which would confirm my understanding? 🙏 Can you also add the sole missing follow-up? 🙏
    2. Naming nit: empty is a fine name, but the inner nerd in me really wants this to be … punnier. Isn there something we can do that is borrowing cooking terminology?
    3. Naming nit: I think comment_base is less precise than it could be. I think comment_structure would be better, because creating this stuff by hand would also fall under the subtree of the information architecture. Alternatively, I think comment_storage also is a better name. Thinking about this more, this is actually specific to Nodes, so comment_for_nodes or comment_storage_for_node probably are better still.
    4. The clear outline in the issue summary combined with the recipe-based-variant of StandardTest allowed me to not check all config in detail, but instead focus on the recipes and their dependencies. This made my life as a reviewer a lot simpler 👍
    5. … which made me realize that one very valuable tool in my toolbox as a Recipe author/reviewer/auditor/evaluator would be to visualize the tree structure of all recipes 🤓🙏 Can we create a follow-up issue for that, to add it as a new console command? Tagged for this.
    6. Regarding restricted_html_format: that's the only text format available to the anonymous user. So as soon as a site decides to allow anonymous users to post comments, it becomes relevant. It's kind of like "optional config not if a module is installed but if one small tweak is made to other config". So I think it does make sense in the Standard install profile.
    7. I spotted a few bugs, have a few questions, a few suggestions … but I think it's looking damn good, and will be comfortable RTBC'ing soon 😊👏

    Great work here! 👍

  • Pipeline finished with Canceled
    4 months ago
    Total: 223s
    #95505
  • Pipeline finished with Success
    4 months ago
    Total: 261s
    #95508
  • Pipeline finished with Failed
    4 months ago
    Total: 241s
    #95568
  • Pipeline finished with Success
    4 months ago
    Total: 298s
    #95584
  • Status changed to Needs review 4 months ago
  • 🇮🇳India narendraR Jaipur, India

    Addressed feedback

  • Status changed to Needs work 4 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    Almost there!

  • Status changed to RTBC 4 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    Sorry, @narendraR, I got confused! I actually have zero remarks left — this is ready IMHO! 🤩

    Congrats on and thank you for this excellent work. It's strong validation of the current state of Recipes! 🎉

    Speaking of which: I think the next thing to do is #3400672: [PP-1] Robustly validate the structure of recipe.yml , while your mind still has the encountered problems fresh, and to help avoid the next recipe author from running into the same problems 😊

  • 🇺🇸United States thejimbirch Cape Cod, Massachusetts

    Updating my attribution.

  • 🇺🇸United States DamienMcKenna NH, USA

    Should this be blocked until #3400672: [PP-1] Robustly validate the structure of recipe.yml is finished, to avoid committing something that might need to be changed soon afterwards?

  • 🇺🇸United States phenaproxima Massachusetts

    No need, @DamienMcKenna. If it needs to be changed (I suspect it will pass all validation), we can just change it.

    Besides, this is ready to go, and #3400672: [PP-1] Robustly validate the structure of recipe.yml has quite a bit of work still needed. If you manually test the recipes in this issue, you'll see that they work as intended. :)

    So, I see no compelling reason to block this.

  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    Agreed with @phenaproxima in #49.

    Who the hell self-hosts videos these days?

    But I disagree with this 😅 My site has zero external dependencies (I want to own/control all content), with the exception of embedding remote videos for e.g. a DrupalCon recording on YouTube (those recordings I do not own).

  • Pipeline finished with Failed
    4 months ago
    Total: 352s
    #105024
  • Pipeline finished with Success
    4 months ago
    Total: 307s
    #105061
  • Pipeline finished with Success
    4 months ago
    Total: 286s
    #105191
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    @phenaproxima or @narendraR Can you please update the metadata + summary of this issue per the discussion in Drupal Slack? 🙏

  • Pipeline finished with Failed
    4 months ago
    Total: 290s
    #107042
  • 🇺🇸United States phenaproxima Massachusetts
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    Thanks!

  • Pipeline finished with Canceled
    4 months ago
    Total: 339s
    #107221
  • Pipeline finished with Canceled
    4 months ago
    Total: 56s
    #107224
  • Pipeline finished with Success
    4 months ago
    Total: 334s
    #107226
  • 🇺🇸United States effulgentsia

    I only reviewed this quickly, but at least on first glance, it looks great!

    I'm curious why core_recommended_themes is a single recipe rather than splitting front-end theme (Olivero) and admin theme (Claro) into separate recipes. For example, might people want to reuse the Claro recipe with a different front-end theme, or reuse the Olivero recipe with Gin or some other admin theme? Is there discussion that led to combining them that I can read up on?

  • 🇺🇸United States thejimbirch Cape Cod, Massachusetts

    The work here always set both themes. Up until the following issue, it was in the primary standard recipe. I believe this is where it was broken out into its own, core_recommended_themes recipe:

    https://www.drupal.org/project/distributions_recipes/issues/3301370#comm...

    They could be broken into their own recipes, but for simplicity's sake, the core_recommended_themes does what it states.

    There are also some sticky things with themes and recipes, like blocks are created from the frontend theme for both the frontend and admin 📌 Copy block configuration from admin theme when enabling an admin theme Active , that we probably don't want to get into in this issue.

  • Status changed to Needs work 4 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    @effulgentsia in #54: That's a very good point! Let's do that. 💪 (@thejimbirch in #55: as long as we install the same theme, just split across two recipes instead of one, AFAICT everything should continue to work exactly the same.)

    Marked for implementing @effulgentsia's suggestion.

    RE: @phenaproxima in https://git.drupalcode.org/project/distributions_recipes/-/merge_request...
    Right, not all core config is validatable today. We have issues to make that happen though, and we're making progress:
    1. currently 11/51 or 22%: 🌱 [meta] Add constraints to all simple configuration Active
    2. currently 6/29 or 20%: 🌱 [meta] Add constraints to all config entity types Active

    But even when we get that to 100%, that still doesn't mean all contrib config will overnight be validatable.

    The good news is that I see a viable middle ground: … only validating config that is marked as FullyValidatable (i.e. has that as a top-level validation constraint).

    Is that great? No.
    Is that realistic? Yes.

    We don’t want Recipes to become too limited to be useful by validating everything, including things that have not yet been made validatable. Because yes, e.g. type: label, type: config_dependencies have gotten validation constraints, which means that virtually all config will have some validatability. But that’s not a guarantee that all the concrete config using those types actually has been updated to comply.
    Hence that FullyValidatable middle ground proposal.

    If you agree, we should postpone this issue on a yet-to-be-created validation-refining Recipes issue. It can copy/paste the logic in \Drupal\KernelTests\Core\Config\ConfigEntityValidationTestBase::isFullyValidatable() to achieve what it needs.

    (That would also solve the simple_config_update scenario that @phenaproxima refers to. To make that scenario (as well as any other config action) comply with this as well, we need to make ConfigActionManager::applyAction() also check whether the modified config is FullyValidatable.)

  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺
  • Status changed to Postponed 4 months ago
  • 🇺🇸United States phenaproxima Massachusetts

    Yeah, I agree with you, Wim. Postponing.

  • Pipeline finished with Success
    4 months ago
    Total: 339s
    #118001
  • 🇮🇳India narendraR Jaipur, India
  • Pipeline finished with Success
    4 months ago
    Total: 316s
    #118034
  • Assigned to Wim Leers
  • Status changed to Needs review 4 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    @effulgentsia's remark about core_recommended_themes in #54 has been addressed 👍

    My reason for postponing this in #56 which @phenaproxima agreed with in #58. I wrote in #57/at #3401925-8: [PP-2] After a recipe is successfully applied, validate all of the config that was imported or modified by config actions to implement the -check there, but that was then extracted into its own issue: #3425540: Only validate config which is fully validatable .

    #3425540: Only validate config which is fully validatable has landed, which means this is unblocked! We should not block this on #3401925: [PP-2] After a recipe is successfully applied, validate all of the config that was imported or modified by config actions , because the scope of that is bigger than the specific thing this was blocked on!

  • Issue was unassigned.
  • Status changed to Needs work 4 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    @effulgentsia's remark about core_recommended_themes in #54 has been addressed 👍

    1. I think this is now truly ready, because the MR being green means more now than an February 15 in #45, since validation is much stronger now 👍
    2. Thanks to #3401925: [PP-2] After a recipe is successfully applied, validate all of the config that was imported or modified by config actions having landed, we should be able to remove the "set langcode if missing" logic.
    3. Since #45/Feb 15, #3418179: [meta] Make config actions more dynamic has also made big steps forward. #3420209: Allow config actions to be applied to multiple config entities using wildcards has landed, and other child issues are nearly ready. So, I re-checked this entire MR to ensure that we're using #3420209 wherever possible. But … AFAICT it's not relevant for the Standard recipe, because it defines a starting point. I think the capabilities that are being added in that meta will be more relevant for recipes like .

    I do think that @alexpott would prefer to not commit this until 🐛 Install profile is disabled for lots of different reasons and core doesn't allow for that Fixed lands, but … I think we could just as easily land this now, so we can get started on the Umami install profile net, and then just remove the empty install profile that this issue is adding.

    Almost ready! 😄

  • Pipeline finished with Failed
    4 months ago
    Total: 312s
    #118103
  • Pipeline finished with Success
    4 months ago
    Total: 345s
    #118220
  • Status changed to Needs review 4 months ago
  • 🇮🇳India narendraR Jaipur, India

    Done #61.2

  • Pipeline finished with Success
    4 months ago
    Total: 435s
    #118797
  • Pipeline finished with Success
    4 months ago
    Total: 343s
    #119298
  • Pipeline finished with Canceled
    3 months ago
    Total: 37s
    #120254
  • Pipeline finished with Success
    3 months ago
    Total: 354s
    #120256
  • Pipeline finished with Canceled
    3 months ago
    Total: 292s
    #120260
  • Pipeline finished with Canceled
    3 months ago
    #120266
  • Pipeline finished with Canceled
    3 months ago
    Total: 173s
    #120269
  • Pipeline finished with Canceled
    3 months ago
    Total: 93s
    #120274
  • Pipeline finished with Canceled
    3 months ago
    Total: 114s
    #120276
  • Pipeline finished with Canceled
    3 months ago
    Total: 241s
    #120281
  • Pipeline finished with Canceled
    3 months ago
    Total: 224s
    #120286
  • Pipeline finished with Canceled
    3 months ago
    Total: 361s
    #120303
  • Pipeline finished with Canceled
    3 months ago
    Total: 87s
    #120313
  • Pipeline finished with Success
    3 months ago
    #120317
  • 🇺🇸United States phenaproxima Massachusetts
  • Status changed to Needs work 3 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    One question on the MR, plus two requested follow-ups based on the big set of changes you've just pushed, @phenaproxima.

  • Status changed to Needs review 3 months ago
  • 🇺🇸United States phenaproxima Massachusetts

    Can you please create a follow-up issue to ensure that "superfluous modules installed" can be a problem we automatically detect and inform the Recipe author of?

    I'm not sure we can ever reliably detect this. The simple reason being: what gives us the right to determine whether an extension is superfluous? By what metric do we decide that? In this issue, it's a judgment call I made based on my intimate knowledge of what we're trying to accomplish here.

    It's entirely possible you'd want to install a module that only exposes simple config, like automatic_updates, and therefore it would only be in the install list, and not mentioned anywhere else in the recipe. But it would not be superfluous.

    Can you please create a follow-up issue to ensure that config.import entries are listed alphabetically and inform the Recipe author that this should be the case?

    I'd really rather not do this. Having them alphabetically is a purely stylistic thing for readability in my opinion, but it's not remotely important and not something we need to warn a recipe author about. If anything, it should be a coding standard, if we develop some coding standards specifically aimed at recipes. And that's just so minor right now that even creating a follow-up seems pointless.

  • Assigned to Wim Leers
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    RE #65: okay, so you're saying that most of what you did in the last ~dozen commits was purely subjective preference than an objective improvement. I wish you'd described that in the commit messages and/or left a comment explaining this. I was under the impression that you deemed these changes necessary, which is why I asked for those follow-ups; to ensure that future recipes are held to the same standards (pun not intended). +1 for not creating follow-ups.

    Ugh, looks like GitLab failed to post my review 😞 can't access it here because it's in the localStorage of my work laptop. I'll post it in the morning… (I can't recall if it should be RTBC-blocking or if it was minor. I bet it was minor … but I also don't want to waste Alex' time, so I'd rather err on the cautious side 😅)

  • 🇺🇸United States phenaproxima Massachusetts

    Overall, yes, I'd say most of what I did was subjective improvement. You could argue that removing superfluous modules was an objective improvement, but they weren't hurting anything by their presence. They were just cruft. It did not occur to me to use my commit messages (which can be awfully short and callous - I'm particularly proud of things like "GET F**KED, PHPSTAN") to explain my reasoning, but I should have left a comment here. My bad.

  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    All good, no worries! 't Was but a mere suggestion to allow me (or whomever is reviewing your indeed often delightful commit messages 😆) to understand your rationale and which level of rigor is appropriate :)

  • Issue was unassigned.
  • Status changed to Needs work 3 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    Posted the comment that failed to post: https://git.drupalcode.org/project/distributions_recipes/-/merge_request...

    This made me wonder why some of those subjective changes are even accurate. And that is why I requested those follow-ups.

  • Pipeline finished with Success
    3 months ago
    Total: 345s
    #123319
  • Status changed to Needs review 3 months ago
  • 🇺🇸United States phenaproxima Massachusetts
  • Status changed to Postponed 3 months ago
  • Status changed to Needs work 3 months ago
  • 🇺🇸United States phenaproxima Massachusetts

    The core blocker landed!

    Our next step here is to remove the Empty profile, and convert our test coverage to apply the Standard recipe suite on top of Minimal, since I imagine that's how most people will actually use these rightnow (it wouldn't make much sense to apply the Standard recipes on top of Standard).

    We'll also need an issue summary update to remove the mention of the Empty profile.

  • 🇺🇸United States phenaproxima Massachusetts

    Updated the IS to remove mentions of Empty.

  • Pipeline finished with Failed
    3 months ago
    Total: 304s
    #125342
  • Pipeline finished with Failed
    3 months ago
    Total: 202s
    #125352
  • Pipeline finished with Failed
    3 months ago
    Total: 173s
    #125355
  • Pipeline finished with Failed
    3 months ago
    Total: 342s
    #125361
  • Status changed to Needs review 3 months ago
  • 🇺🇸United States phenaproxima Massachusetts
  • Pipeline finished with Success
    3 months ago
    Total: 420s
    #125374
  • Status changed to RTBC 3 months ago
  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    🤩

    P.S.: there's a single line whitespace-only change in Recipe.php that could be reverted.

  • 🇺🇸United States phenaproxima Massachusetts

    I...I don't think it need be blocked on that. Not sure why it was. Fixing.

  • Status changed to Needs work 3 months ago
  • 🇬🇧United Kingdom alexpott 🇪🇺🌍

    So rather than painstakingly review all the config the standard recipes create and check against the standard profile I thought I'd make the test do that for us. This will ensure if there are change in core's Standard profile we'll find them.

    This gives us some things to fix:

    1) Drupal\FunctionalTests\Core\Recipe\StandardRecipeTest::testStandard
    Failed asserting that two arrays are identical.
    --- Expected
    +++ Actual
    @@ @@
     Array &0 (
    -    'create' => Array &1 ()
    +    'create' => Array &1 (
    +        0 => 'claro.settings'
    +        1 => 'core.entity_view_mode.media.full'
    +        2 => 'image.style.media_library'
    +        3 => 'shortcut.set.default'
    +        4 => 'system.action.media_delete_action'
    +        5 => 'system.action.media_publish_action'
    +        6 => 'system.action.media_save_action'
    +        7 => 'system.action.media_unpublish_action'
    +        8 => 'views.view.media'
    +        9 => 'views.view.media_library'
    +    )
         'update' => Array &2 (
             0 => 'core.extension'
    +        1 => 'field.field.media.image.field_media_image'
    +        2 => 'core.entity_view_display.media.remote_video.default'
    +        3 => 'node.settings'
    +        4 => 'core.entity_view_display.node.article.teaser'
    +        5 => 'user.role.authenticated'
         )
         'delete' => Array &3 ()
         'rename' => Array &4 ()
     )
    

    We need to fix it so that the only thing changing is core.extension. Or we agree to not do something... ie. the shortcuts. It seems we're not creating the media views. I think we should be doing that. The missing claro.settings is interesting too.

  • Pipeline finished with Failed
    3 months ago
    Total: 452s
    #126194
  • Pipeline finished with Failed
    3 months ago
    Total: 389s
    #126256
  • Pipeline finished with Failed
    3 months ago
    Total: 204s
    #126316
  • Pipeline finished with Failed
    3 months ago
    Total: 382s
    #126318
  • Status changed to RTBC 3 months ago
  • 🇬🇧United Kingdom alexpott 🇪🇺🌍

    Okay we're green and found two kinda config bugs in Standard FTW. Let's do this!

    • alexpott committed 5cb4c11b on 10.3.x
      Issue #3417835 by phenaproxima, narendraR, alexpott, Wim Leers,...
  • Status changed to Fixed 3 months ago
    • alexpott committed 66cf09c2 on 11.x
      Issue #3417835 by phenaproxima, narendraR, alexpott, Wim Leers,...
  • 🇬🇧United Kingdom alexpott 🇪🇺🌍

    Woot

    • ed7cce01 committed on patch
      Update recipe 10.3.x patch 5cb4c11b Issue #3417835 by phenaproxima,...
    • e78c8319 committed on patch
      Update recipe 11.x patch 66cf09c2 Issue #3417835 by phenaproxima,...
  • 🇺🇸United States thejimbirch Cape Cod, Massachusetts

    Amazing! Great work everyone!

  • 🇧🇪Belgium Wim Leers Ghent 🇧🇪🇪🇺

    🥳🥳🥳

    Best thing to happen all week!

    • alexpott committed 6b6d1078 on 10.3.x
      Issue #3417835 follow-up by alexpott: Convert the Standard install...
    • alexpott committed e22dd52d on 11.x
      Issue #3417835 follow-up by alexpott: Convert the Standard install...
    • d04190c4 committed on patch
      Update recipe 10.3.x patch 6b6d1078 Issue #3417835 follow-up by alexpott...
    • af2ab3ad committed on patch
      Update recipe 11.x patch e22dd52d Issue #3417835 follow-up by alexpott:...
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.69.0 2024