@@ -451,7 +451,7 @@ func getMappingDefinitionsField(field string, definition map[string]any) (map[st
451451 anyValue := definition [field ]
452452 object , ok := anyValue .(map [string ]any )
453453 if ! ok {
454- return nil , fmt .Errorf ("unexpected type found for %s : %T " , field , anyValue )
454+ return nil , fmt .Errorf ("unexpected type found for %q : %T " , field , anyValue )
455455 }
456456 return object , nil
457457}
@@ -493,22 +493,22 @@ func (v *MappingValidator) compareMappings(path string, preview, actual map[stri
493493 }
494494
495495 if slices .Contains (v .exceptionFields , path ) {
496- logger .Warnf ("Found exception field, skip its validation: %s " , path )
496+ logger .Warnf ("Found exception field, skip its validation: %q " , path )
497497 return nil
498498 }
499499
500500 if isObjectFullyDynamic (actual ) {
501- logger .Debugf ("Dynamic object found but no fields ingested under path: %s.*" , path )
501+ logger .Debugf ("Dynamic object found but no fields ingested under path: \" %s.*\" " , path )
502502 return nil
503503 }
504504
505505 if isObject (actual ) {
506506 if isObjectFullyDynamic (preview ) {
507507 // TODO: Skip for now, it should be required to compare with dynamic templates
508- logger .Debugf ("Pending to validate with the dynamic templates defined the path: %s " , path )
508+ logger .Debugf ("Pending to validate with the dynamic templates defined the path: %q " , path )
509509 return nil
510510 } else if ! isObject (preview ) {
511- errs = append (errs , fmt .Errorf ("not found properties in preview mappings for path: %s " , path ))
511+ errs = append (errs , fmt .Errorf ("not found properties in preview mappings for path: %q " , path ))
512512 return errs .Unique ()
513513 }
514514 previewProperties , err := getMappingDefinitionsField ("properties" , preview )
@@ -531,7 +531,7 @@ func (v *MappingValidator) compareMappings(path string, preview, actual map[stri
531531 containsMultifield := isMultiFields (actual )
532532 if containsMultifield {
533533 if ! isMultiFields (preview ) {
534- errs = append (errs , fmt .Errorf ("not found multi_fields in preview mappings for path: %s " , path ))
534+ errs = append (errs , fmt .Errorf ("not found multi_fields in preview mappings for path: %q " , path ))
535535 return errs .Unique ()
536536 }
537537 previewFields , err := getMappingDefinitionsField ("fields" , preview )
@@ -604,7 +604,7 @@ func (v *MappingValidator) validateMappingsNotInPreview(currentPath string, chil
604604
605605 for fieldPath , object := range flattenFields {
606606 if slices .Contains (v .exceptionFields , fieldPath ) {
607- logger .Warnf ("Found exception field, skip its validation: %s " , fieldPath )
607+ logger .Warnf ("Found exception field, skip its validation: %q " , fieldPath )
608608 return nil
609609 }
610610
0 commit comments