Config Translation only supports `translatable: true` at the top level, but has no validation to indicate this

Created on 22 March 2023, about 1 year ago
Updated 23 March 2023, about 1 year ago

Problem/Motivation

In #3341682-11: Add config validation to the "label" config schema data type โ†’ , I discovered that setting translatable: true in a config schema has zero effect.

Turns out that only translatable: true on config schema types is allowed! That's how config_translation_config_schema_info_alter() works.

Steps to reproduce

Specify translatable: true for anything that isn't top-level in the schema, and observe it has no effect in the config translation UI!

Proposed resolution

Add validation for developers.

Remaining tasks

TBD

User interface changes

None.

API changes

None.

Data model changes

None.

Release notes snippet

TBD

๐Ÿ› Bug report
Status

Needs work

Version

10.1 โœจ

Component
Config translationย  โ†’

Last updated about 1 month ago

Created by

๐Ÿ‡ง๐Ÿ‡ชBelgium Wim Leers Ghent ๐Ÿ‡ง๐Ÿ‡ช๐Ÿ‡ช๐Ÿ‡บ

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

Comments & Activities

  • Issue created by @Wim Leers
  • Status changed to Needs review about 1 year ago
  • ๐Ÿ‡ง๐Ÿ‡ชBelgium Wim Leers Ghent ๐Ÿ‡ง๐Ÿ‡ช๐Ÿ‡ช๐Ÿ‡บ

    This should fail like so:

    Testing /Users/wim.leers/core/core/modules/config_translation/tests/src/Functional
    .                                                                   1 / 1 (100%)
    
    Time: 00:13.523, Memory: 10.00 MB
    
    OK (1 test, 28 assertions)
    
    Unsilenced deprecation notices (12)
    
      12x: The `field.value.created.mapping` config schema specifies the `translatable` property, but the config_translation module only supports this for types.
        12x in ConfigTranslationUiTest::testSourceValueDuplicateSave from Drupal\Tests\config_translation\Functional
    
  • Status changed to Needs work about 1 year ago
  • The Needs Review Queue Bot โ†’ tested this issue. It fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".

    Apart from a re-roll or rebase, this issue may need more work to address feedback in the issue or MR comments. To progress an issue, incorporate this feedback as part of the process of updating the issue. This helps other contributors to know what is outstanding.

    Consult the Drupal Contributor Guide โ†’ to find step-by-step guides for working with issues.

  • ๐Ÿ‡ฎ๐Ÿ‡ณIndia Nitin shrivastava

    Try to fix CCF error.

  • Status changed to Needs review about 1 year ago
  • ๐Ÿ‡ง๐Ÿ‡ชBelgium borisson_ Mechelen, ๐Ÿ‡ง๐Ÿ‡ช

    NR so the bot can look at #4.

  • Status changed to Needs work about 1 year ago
  • ๐Ÿ‡ง๐Ÿ‡ชBelgium borisson_ Mechelen, ๐Ÿ‡ง๐Ÿ‡ช

    #2 tells us that this should fail, but I can't find any of those errors in the output, is that because the fail patch is no longer there?

    In any case, back to needs work for the todo in the code (making it recursive).

Production build 0.69.0 2024