Temporarily disable field updates - Testing which updates cause upload failure
Issue: After adding field updates, uploads return HTTP 202 but assets don't appear Field Updates DISABLED for testing: 1. ARTESIA.FIELD.ASSET DESCRIPTION (from filename) 2. FERRERO.FIELD.STATE (force to Local) 3. FERRERO.MARKETING.CREATOR (Oliver Agency) Findings from lookup domains: ✅ FERRERO.FIELD.STATE domain values: Global, Local (valid) ❌ FERRERO.MARKETING.CREATOR: 1,893 specific values (emails/usernames) - 'Oliver Agency' NOT in list - Valid options: 'ExternalAgency', 'ExternalAgencynew' Video metadata: - Still extracted via ffprobe - Only logged, not sent to DAM - Let DAM analyze video files automatically Next Step: Test upload with field updates disabled. If works → Re-enable one at a time to find the breaking change. 🤖 Generated with Claude Code
This commit is contained in:
parent
5b050c2483
commit
dfaa1fe4de
1 changed files with 18 additions and 26 deletions
|
|
@ -308,6 +308,8 @@ class MetadataExtractorMVP
|
|||
}
|
||||
|
||||
// 4. Update ARTESIA.FIELD.ASSET DESCRIPTION from filename subject_title
|
||||
// TEMPORARILY DISABLED - Testing if this causes upload failure
|
||||
/*
|
||||
if ($parsedFilename && !empty($parsedFilename['subject_title'])) {
|
||||
$description = $parsedFilename['subject_title'];
|
||||
foreach ($mvpFields as &$field) {
|
||||
|
|
@ -322,8 +324,11 @@ class MetadataExtractorMVP
|
|||
}
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
// 5. Force FERRERO.FIELD.STATE to "Local" for all uploads
|
||||
// TEMPORARILY DISABLED - Testing if this causes upload failure
|
||||
/*
|
||||
foreach ($mvpFields as &$field) {
|
||||
if ($field['id'] === 'FERRERO.FIELD.STATE') {
|
||||
if (isset($field['value']['value']['value'])) {
|
||||
|
|
@ -335,49 +340,36 @@ class MetadataExtractorMVP
|
|||
break;
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
// 6. Update video technical metadata if available
|
||||
if (!empty($videoMetadata)) {
|
||||
error_log("MVP Extractor: Updating video metadata - {$videoMetadata['width']}x{$videoMetadata['height']}, Duration: {$videoMetadata['duration']}s");
|
||||
|
||||
// Note: Video technical fields like bitrate, duration, frame dimensions
|
||||
// are typically stored in content_info, not in metadata fields
|
||||
// We'll log them but they may need to be added to the upload manifest instead
|
||||
// For now, just log them for reference
|
||||
error_log("MVP Extractor: Video metadata extracted - {$videoMetadata['width']}x{$videoMetadata['height']}, Duration: {$videoMetadata['duration']}s");
|
||||
// Let DAM analyze video files automatically - don't send technical metadata
|
||||
}
|
||||
|
||||
// 7. Add or update FERRERO.MARKETING.CREATOR (Uploaded by) to "Oliver Agency"
|
||||
// 7. CREATOR field - TEMPORARILY DISABLED
|
||||
// "Oliver Agency" is NOT in the domain values (1893 specific emails/usernames)
|
||||
// Valid values include: "ExternalAgency", "ExternalAgencynew"
|
||||
// Commenting out until we confirm which value to use
|
||||
/*
|
||||
$creatorFieldIndex = null;
|
||||
foreach ($mvpFields as $index => &$field) {
|
||||
if ($field['id'] === 'FERRERO.MARKETING.CREATOR') {
|
||||
$creatorFieldIndex = $index;
|
||||
// Update existing field
|
||||
if (isset($field['value']['value']['value'])) {
|
||||
$field['value']['value']['value'] = 'Oliver Agency';
|
||||
$field['value']['value']['value'] = 'ExternalAgency'; // Valid domain value
|
||||
} elseif (isset($field['value']['value']['field_value']['value'])) {
|
||||
$field['value']['value']['field_value']['value'] = 'Oliver Agency';
|
||||
$field['value']['value']['field_value']['value'] = 'ExternalAgency';
|
||||
}
|
||||
error_log("MVP Extractor: Updated CREATOR to: Oliver Agency");
|
||||
error_log("MVP Extractor: Updated CREATOR to: ExternalAgency");
|
||||
break;
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
// Add if not found
|
||||
if ($creatorFieldIndex === null) {
|
||||
error_log("MVP Extractor: Adding FERRERO.MARKETING.CREATOR: Oliver Agency");
|
||||
$mvpFields[] = [
|
||||
'id' => 'FERRERO.MARKETING.CREATOR',
|
||||
'type' => 'com.artesia.metadata.MetadataField',
|
||||
'value' => [
|
||||
'cascading_domain_value' => false,
|
||||
'domain_value' => false,
|
||||
'value' => [
|
||||
'type' => 'string',
|
||||
'value' => 'Oliver Agency'
|
||||
]
|
||||
]
|
||||
];
|
||||
}
|
||||
error_log("MVP Extractor: Field updates temporarily disabled for testing");
|
||||
|
||||
return $mvpFields;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue