Bug #13144

Creating a digital object without path raises an error in 2.5.x

Added by José Raddaoui Marín about 1 month ago. Updated 30 days ago.

Status:VerifiedStart date:08/12/2019
Priority:MediumDue date:
Assignee:Dan Gillean% Done:

0%

Category:Digital object
Target version:Release 2.5.2
Google Code Legacy ID: Tested version:2.5
Sponsored:No Requires documentation:

Description

To reproduce:

- Perform a metadata only DIP upload from AM.

Notes:

The path column from DO table has a NOT NULL clause without a default value. This is causing MySQL errors when the DO is created from the metadata only DIP upload request (I think it's the only place for now), where the DO has an "Offline" usage and no path.

This issue came out now probably because of the upgrade to MySQL 5.7 and/or the re-addition of STRICT_TRANS_TABLES to the sql_mode. Options to fix it:

1. Remove the NOT NULL clause or add a default value to the column (requires migration).
2. Remove STRICT_TRANS_TABLES from sql_mode (less secure database and requires documentation and deploy changes).
3. Make sure path is not NULL on DO save.

History

#1 Updated by José Raddaoui Marín about 1 month ago

  • Status changed from New to Code Review

I went with option 3 to avoid the requirements of 1 and 2 in a minor release:

https://github.com/artefactual/atom/pull/950

#2 Updated by Mike Cantelon about 1 month ago

  • Status changed from Code Review to Feedback

Looks good to me!

#3 Updated by José Raddaoui Marín about 1 month ago

  • Status changed from Feedback to QA/Review
  • Assignee changed from José Raddaoui Marín to Dan Gillean

Thanks Mike!

Ready for testing in qa/2.6.x and dev/dip-upload-stable (based on stable/2.5.x with all the DIP upload related fixes).

#4 Updated by José Raddaoui Marín about 1 month ago

To verify this one, make sure all descriptions are created from a metadata only DIP upload, without errors from the AtoM API.

#5 Updated by Sara Allain 30 days ago

  • Status changed from QA/Review to Verified

Also available in: Atom PDF