Automated Drupal 9 compatibility fixes

Created on 6 June 2020, over 4 years ago
Updated 26 January 2023, almost 2 years ago

Problem/Motivation

Hello project maintainers,
This is an automated issue to help make this module compatible with Drupal 9.

To read more about this effort by the Drupal Association, please read: Accelerating Drupal 9 module and theme readiness with automated patches

Periodically patches will be added to this issue that remove Drupal 9 deprecations. To stop further patches from being posted simply close this issue(any status besides Active, Needs Review or Needs work) or remove the "ProjectUpdateBotD9" tag from the issue.

The patches will be posted by the Project Update Bot official user account. This account will not receive any issue credit contributions for itself or any company.

Proposed resolution

You have a few options for how to use this issue:

  1. Accept automated patches until this issue is closed

    If this issue is left open(status of Active, Needs Review or Needs work) and the "ProjectUpdateBotD9" tag is left on this issue, new patches will be posted periodically if new deprecations are needed.

    As the Drupal Rector project improves and is able to fix more deprecations the patches posted here will cover more of the deprecations in the module.

  2. Leave open but stop new automated patches.

    If you want to use this issue as a starting point to remove deprecations but don't want new automated patches simply leave this issue open but remove the "ProjectUpdateBotD9" from the issue.

    You can use Drupal Rector yourself to make these patches.

    If you want to receive automated patches again simply add back the "ProjectUpdateBotD9" tag.

  3. Close it and don't use it

    If the maintainers of this project don't find this issue useful they can simply close this issue(any status besides Active, Needs Review or Needs work) and no more automated patches will be posted here.

    If the issue is reopened then new automated patches will be posted.

    If you are using another issue(s) to work on Drupal 9 compatibility it may be useful to other contributors to add those issues as "Related issues" when closing this issue.

Remaining tasks

Using the patches

  1. Apply the patch in the comment by Project Update Bot
  2. Thoroughly test the patch. These patches are automatically generated so they haven't been tested manually or automatically.

Providing feedback

If there are problems with one of the patches posted by the Project Update Bot , such as it does not correctly replace a deprecation, you can file an issue in the Rector issue queue . For other issues with the bot, for instance if the issue summary created by the bot is unclear,  use the Infrastructure project issue queue using the component “Bot: Drupal Rector”.

📌 Task
Status

Needs work

Version

1.0

Component

Code

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

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

  • 🇺🇸United States rishi kulshreshtha
    ================================================================================
    Feeds Paragraphs, --
    Scanned on Thu, 01/26/2023 - 11:44
    
    FILE: web/modules/contrib/feeds_para_mapper/feeds_para_mapper.info.yml
    
    STATUS         LINE                           MESSAGE                           
    --------------------------------------------------------------------------------
    Check manually 0    Add core_version_requirement: ^8 || ^9 to designate that the
                        extension is compatible with Drupal 9. See                  
                        https://drupal.org/node/3070687.                            
    --------------------------------------------------------------------------------
    
    FILE: web/modules/contrib/feeds_para_mapper/composer.json
    
    STATUS         LINE                           MESSAGE                           
    --------------------------------------------------------------------------------
    Check manually 0    The drupal/core requirement is not compatible with the next 
                        major version of Drupal. Either remove it or update it to be
                        compatible. See                                             
                        https://drupal.org/node/2514612#s-drupal-9-compatibility.   
    --------------------------------------------------------------------------------
    

    This still needs work for D9!

  • @rishi-kulshreshtha opened merge request.
  • Issue was unassigned.
  • Status changed to Needs review almost 2 years ago
  • 🇺🇸United States rishi kulshreshtha

    To test the MR, kindly update your composer.json's repositories with the following:

        "repositories": [
            {
                "type": "composer",
                "url": "https://packages.drupal.org/8",
                "exclude": [
                    "drupal/feeds_para_mapper"
                ]
            },
            {
                "type": "git",
                "url": "https://git.drupalcode.org/issue/feeds_para_mapper-3147462.git"
            }
        ],
    

    After that execute, composer require 'drupal/feeds_para_mapper:dev-3147462-automated-drupal-9'. Ensure that the minimum-stability in your composer.json is set to dev.

  • 🇺🇸United States rishi kulshreshtha

    I want co-maintainership and I promise to abide by the conditions of the Open Ownership Pledge as described. I have provided patches for one of the corresponding issues.

  • 🇺🇸United States zaurav McLean, VA

    Hey Rishi,
    Thanks for taking point. I am currently pulling in using your comment on https://www.drupal.org/project/feeds_para_mapper/issues/3147462#comment-... 📌 Automated Drupal 9 compatibility fixes Needs review

    I see the original maintainer hasn't checked PR in 3 months! Hoping this breathes new life into this module!

    Cheers.

  • 🇨🇦Canada liquidcms

    is that the right format for adding the repo? I use this:

        "repositories": {
            "0": {
                "type": "composer",
                "url": "https://packages.drupal.org/8",
                "exclude": [
                    "drupal/feeds_para_mapper"
                ]
            },
            "feeds_para_mapper": {
                "type": "git",
                "url": "https://git.drupalcode.org/issue/feeds_para_mapper-3147462.git"
            }
        }

    doing this and the composer require listed in #7 and module installs.

    Throws error on most Feed type setup pages though:

    The website encountered an unexpected error. Please try again later.
    TypeError: in_array(): Argument #2 ($haystack) must be of type array, null given in in_array() (line 64 of modules\contrib\feeds_para_mapper\src\Mapper.php).
    
    in_array('entity_reference', NULL) (Line: 64)
    Drupal\feeds_para_mapper\Mapper->getTargets('node', 'department') (Line: 92)
    Drupal\feeds_para_mapper\Feeds\Target\WrapperTarget::targets(Array, Object, Array) (Line: 305)

    Also noticed before adding this module that there is already something in Feeds core which seems to be trying to map multi paragraphs - but doesnt quite work. Wondering if this work is being repeated by the core module?

  • Status changed to Fixed 25 days ago
  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024