sul-dlss / cocina-models

Cocina repository data model (implemented in Ruby)
https://sul-dlss.github.io/cocina-models/
3 stars 0 forks source link

Description type validation #380

Closed justinlittman closed 2 years ago

justinlittman commented 2 years ago

NOTE: Changes to openapi.yml require updating openapi.yml for sdr-api and dor-services-app and generating models - see README.

Why was this change made? 🤔

To have valid data you have to validate it.

How was this change tested? 🤨

âš¡ âš  If this change has cross service impact, run integration tests and/or test in [stage|qa] environment, in addition to specs. âš¡

Unit

justinlittman commented 2 years ago

@arcadiafalcone I'm going to leave this as a draft until you've had a chance to make changes to description_types.yml. Feel free to make PRs against this branch.

justinlittman commented 2 years ago

Before:

Status (n=250000; not using Missing for success/different/error stats):
  Success:   249519 (99.888%)
  Different: 280 (0.112%)
  Mapping error:     0 (0.0%)
  Create error:     0 (0.0%)
  Normalization error:     0 (0.0%)
  Missing from cache:     0 (0.0%)
  Unmapped:     0 (0.0%)
  Expected unmapped:     201 (0.08%)
  Bad cache:     0 (0.0%)
  Validate error:     0 (0.0%)

After:

Status (n=250000; not using Missing for success/different/error stats):
  Success:   249518 (99.888%)
  Different: 280 (0.112%)
  Mapping error:     1 (0.0%)
  Create error:     0 (0.0%)
  Normalization error:     0 (0.0%)
  Missing from cache:     0 (0.0%)
  Unmapped:     0 (0.0%)
  Expected unmapped:     201 (0.08%)
  Bad cache:     0 (0.0%)
  Validate error:     0 (0.0%)

The mapping error was unrelated and ticketed as https://github.com/sul-dlss/dor-services-app/issues/3853