better error handling foracdd  metadataExtracter