Problem/Motivation

This is a follow up to #2208401: [META] Remaining multilingual migration paths to tidy up the migration state files modules/*/migration/state.

Title says it all. There are @todos in the relevant *.migrate_drupal.yml files pointing to

- #2208401: [META] Remaining multilingual migration paths
- #3073050: Migrate D7 i18n taxonomy term field translations

that indicate those are the last issues to be able to mark those as finished. They've been fixed, but the metadata has not been updated accordingly.

Steps to reproduce

Proposed resolution

Set the i18n migrations to finished, removing @todos from the state files.
Update tests.

Remaining tasks

User interface changes

API changes

Data model changes

Release notes snippet

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Wim Leers created an issue. See original summary.

Wim Leers’s picture

Status: Active » Needs review
FileSize
2.52 KB
quietone’s picture

Status: Needs review » Postponed (maintainer needs more info)

@Wim Leers, thanks for opening this issue. Unfortunately, the Meta was closed before all the child issues were committed and I didn't remember that there were todos referring to it in core. This needs to wait on at least, #3008028: Migrate D7 i18n menu links.

quietone’s picture

Status: Postponed (maintainer needs more info) » Postponed

Sorry, meant that to be just 'postponed'

Wim Leers’s picture

👍

quietone’s picture

Title: Mark i18n → config_translation, i18n → content_translation and i18n_taxonomy → content_translation migrations as finished » Mark i18n migrations as finished
Status: Postponed » Needs review
Issue tags: +i18n-migrate, +migrate-d6-d8
FileSize
10.4 KB

Let's expand this to update the D6 states as well. And simplified by the title.

quietone’s picture

Ignore that patch.

Status: Needs review » Needs work

The last submitted patch, 7: 3175729-7.patch, failed testing. View results

quietone’s picture

Status: Needs work » Needs review
FileSize
2.28 KB
10.65 KB

Adjusting the tests for the updated states.

quietone’s picture

Issue summary: View changes

Version: 9.1.x-dev » 9.2.x-dev

Drupal 9.1.0-alpha1 will be released the week of October 19, 2020, which means new developments and disruptive changes should now be targeted for the 9.2.x-dev branch. For more information see the Drupal 9 minor version schedule and the Allowed changes during the Drupal 9 release cycle.

quietone’s picture

Assigned: Unassigned » quietone

I want to review this again.

idebr’s picture

quietone’s picture

Needed a reroll.

quietone’s picture

Assigned: quietone » Unassigned

This is ready for review now.

quietone’s picture

Issue summary: View changes
benjifisher’s picture

@idebr: "Complete" does not mean "completely bug free".

benjifisher’s picture

Status: Needs review » Needs work
  1. Why remove i18nstrings?

     +++ b/core/modules/config_translation/migrations/state/config_translation.migrate_drupal.yml
     @@ -1,28 +1,15 @@
     ...
      finished:
     ...
     -    i18nstrings: config_translation
  2. Does locale: language belong in this file?

        6:
          locale: language
        7:
     -    locale: language
     +    locale: language
Pooja Ganjage’s picture

Hi,

Creating a patch as suggested in #18 comment.

Please review the patch.

Thanks.

Pooja Ganjage’s picture

Status: Needs work » Needs review
daffie’s picture

Status: Needs review » Needs work

Patch failed to apply.

Pooja Ganjage’s picture

benjifisher’s picture

In #18, I asked questions. I do not know the answers to those questions. We should not update the patch until the questions are answered.

quietone’s picture

Status: Needs work » Needs review
Issue tags: +Needs followup
FileSize
2.61 KB
11.56 KB

From 18
1. Very good question. I think it was a simple mistake but it got me looking further. There is a migrate_drupal state file which had i18n entries for d6. Those are now moved to config_translation or content_translation and i18nstrings is restored. That cleans up the migrate_drupal state file to contain a variety of legacy modules that are now in core. It is a nice cleanup.
2. Those lines make no sense. It is supposed to be 'legacy module: destination module' and there is no language module. Those can be deleted.

Point 2, raises the question about what to do when the destination module is not enabled on the destination site. Typically, the destination module provides the migrations but that is not always the case. Or, it could just be a typo in the state file. In any case, the UI checks the state files and plugins etc but there is no check that the destination module is actually enabled. So, the UI could show that it will be upgraded when it will not be. Sigh. Probably needs a follow up for to consider that, adding tag.

benjifisher’s picture

Status: Needs review » Needs work

But there is a language module, and language.migrate_drupal.yml includes

finished:
  6:
    ...
    locale:
      - language
      - system
    ...
  7:
    ...
    locale:
      - language
      - system
    ...

I would say to move the lines there from config_translation.migrate_drupal.yml, but they are already in the right place so we just have to remove them from the wrong place.

Or maybe the right thing to do is change the lines so that config_translation.migrate_drupal.yml has locale: config_translation.

Since the previous patch, you have moved four lines i18n...: content_translation from the migrate_drupal module to the content_translation module. That makes sense. But you also added i18n_string: config_translation there. That looks like a mistake. That line is already in the file for the config_translation module (D7 only).

quietone’s picture

Grr! I need another holiday!

quietone’s picture

Status: Needs work » Needs review
FileSize
567 bytes
11.7 KB

I do not know what planet I was visiting when I last worked on this. :-(

First, this needs a reroll.

quietone’s picture

Ok, now restore the lines in config_translation.migrate_drupal.yml. locale: language. For background that was added in #2936365: Migrate UI - allow modules to declare the state of their migrations. And fix the copy/paste error benjifisher found and pointed out in the last paragraph of #25.

This should now be back on track.

Status: Needs review » Needs work

The last submitted patch, 28: 3175729-28.patch, failed testing. View results

quietone’s picture

Status: Needs work » Needs review
FileSize
892 bytes

Not sure how I lost this one line change.

benjifisher’s picture

Status: Needs review » Needs work

@quietone:

Have a cup of tea and upload the patch along with the interdiff for #30. ;)

quietone’s picture

Status: Needs work » Needs review
FileSize
11.84 KB

Lol, you are soo right!

Here is the patch for #30.

quietone’s picture

Issue tags: -Needs followup

I am no longer convinced that a follow up is needed as I was thinking in #24. MigationState does build the migration so all the checkRequirements are done so all should be well. Also, did a test with a destination module with a typo,

finished:
    help: block2

Results in help being listed in the will not be upgraded with a destination module of block2. That is sufficient to alert someone that block2 does not exist.

Removing needs follow up tag.

benjifisher’s picture

Status: Needs review » Reviewed & tested by the community

The patch in #32 (labeled for #30) looks good to me. Quick, commit this before it needs another reroll!

  • catch committed 418c3a2 on 9.2.x
    Issue #3175729 by quietone, Pooja Ganjage, Wim Leers, benjifisher: Mark...
catch’s picture

Status: Reviewed & tested by the community » Fixed

Committed/pushed to 9.2.x, thanks!

This doesn't cherry-pick cleanly to 9.1.x - I'm not sure if the intention here was to backport it to 9.1.x or not (or whether we should), so marking fixed - but if it should go back then please re-open with a re-roll.

quietone’s picture

Back in #3, this was postponed on #3008028: Migrate D7 i18n menu links. That was committed to 9.1.x so, yes, this can be committed to 9.1.x as well. The question remains, should we do that? What are the reasons not to backport? I can't think of any.

Here is a 9.1 patch in case there is agreement to backport.

catch’s picture

Version: 9.2.x-dev » 9.1.x-dev
Status: Fixed » Reviewed & tested by the community

Also can't see a reason not to backport. Changing status and kicking off a test run.

quietone’s picture

Title: Mark i18n migrations as finished » [backport] Mark i18n migrations as finished

I think this gets backport added to the title

  • catch committed ee8c012 on 9.1.x
    Issue #3175729 by quietone, Pooja Ganjage, Wim Leers, benjifisher, catch...
catch’s picture

Status: Reviewed & tested by the community » Fixed

Committed ee8c012 and pushed to 9.1.x. Thanks!

quietone’s picture

Title: [backport] Mark i18n migrations as finished » Mark i18n migrations as finished

@catch, thank you.

Removing [backport] from the title.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.