ImageImport doesn't seem to work at all

Created on 27 August 2024, 4 months ago

Problem/Motivation

I am trying to use ImageImport, but it breaks while trying to to do the filecopy. When I am inspecting the bug the code doesn't seem to make sense at all, because the ImageImport::transform method is expecting $value to be an array (for example it is using $value['target_id']). However, it immediately passes that array to the FileImport class, which expects the $value to be a string (for example it copies $value to $source and prints it in an error message later and also sourceExists expects it to be a string).

So how can this work at all? Am I missing something completely?

Steps to reproduce

Trying to process:

  field_image:
    plugin: image_import
    source: field_image
    destination: constants/file_destination
    skip_on_missing_source: true
    file_exists: 'use existing'
    title: title
    alt: alt
    width: width
    height: height

Proposed resolution

Fix the code. I would like to help, but I cannot yet make sense of how it is supposed to work.

Remaining tasks

User interface changes

API changes

Data model changes

🐛 Bug report
Status

Active

Version

2.1

Component

Code

Created by

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

Comments & Activities

Production build 0.71.5 2024