Destination file storage should clear existing file on dataset update

Created on 20 December 2022, over 1 year ago
Updated 2 January 2024, 6 months ago

Problem/Motivation

Updating and processing the existing dataset appends content to the existing file instead of recreating it.
\Drupal\data_pipelines\Plugin\DatasetDestination\JsonDestination is used.

Steps to reproduce

  1. Create a dataset with JsonDestination.
  2. Process it.
  3. Check the destination file.
  4. Update the dataset and upload a new source file
  5. Update the dataset and process it.
  6. Check the destination file. Now it has duplicate data

Proposed resolution

Delete the destination file before creating a new one.

Remaining tasks

  • Tests
  • Review
  • Commit
  • Rejoice

User interface changes

None

API changes

None

Data model changes

None.

πŸ› Bug report
Status

Fixed

Version

1.0

Component

Code

Created by

πŸ‡΅πŸ‡°Pakistan jibran Sydney, Australia

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

Merge Requests

Comments & Activities

Not all content is available!

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

Production build 0.69.0 2024