Allow JSONAPI POST/PATCH to include fields that are not present.

Created on 20 September 2023, about 1 year ago

Problem/Motivation

Unable to POST remotely: Unprocessable Entity 422: The attribute X does not exist on the site--drupal resource type

Steps to reproduce

  1. Enable site module.
  2. Add a field.
  3. Refresh data.
  4. See Unable to POST remotely: Unprocessable Entity 422: The attribute X does not exist on the site--drupal resource type

Happens when any module changes the entity structure, such as metatag.

Proposed resolution

Add SiteEntity::validate() to remove violations about missing fields when received via JSONAPI.

Remaining tasks

Add SiteEntity::validate() to remove violations about missing fields when received via JSONAPI.
Save something to revision log about the missing fields.

User interface changes

The revision log should show info about the missing fields.

API changes

SiteEntity->validate() will allow missing fields if POST/PATCH via JSONAPI routes.

Data model changes

None.

πŸ“Œ Task
Status

Active

Version

2.0

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States Jon Pugh Newburgh, NY

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

Comments & Activities

Production build 0.71.5 2024