@@ -86,22 +86,23 @@ func componentFunc(cliConfig schema.CliConfiguration, component string, stack st
8686 y , err2 := u .ConvertToYAML (outputMeta )
8787 if err2 != nil {
8888 u .LogError (err2 )
89+ } else {
90+ u .LogTrace (cliConfig , fmt .Sprintf ("\n Result of 'atmos terraform output %s -s %s' before processing it:\n %s\n " , component , stack , y ))
8991 }
90- u .LogTrace (cliConfig , fmt .Sprintf ("\n Result of 'atmos terraform output %s -s %s' before processing it:\n %s\n " , component , stack , y ))
9192 }
9293
9394 outputMetaProcessed := lo .MapEntries (outputMeta , func (k string , v tfexec.OutputMeta ) (string , any ) {
9495 s := string (v .Value )
95- u .LogTrace (cliConfig , fmt .Sprintf ("Converting the variable %s from JSON to string representation \n " , s ))
96+ u .LogTrace (cliConfig , fmt .Sprintf ("Converting the variable '%s' with the value \n %s \n from JSON to 'Go' data type \n " , k , s ))
9697
9798 d , err2 := u .ConvertFromJSON (s )
9899
99100 if err2 != nil {
100101 u .LogError (err2 )
102+ } else {
103+ u .LogTrace (cliConfig , fmt .Sprintf ("Converted the variable '%s' with the value\n %s\n from JSON to 'Go' data type\n Result: %v\n " , k , s , d ))
101104 }
102105
103- u .LogTrace (cliConfig , fmt .Sprintf ("Converted the variable %s from JSON to string representation.\n Result: %s\n " , s , d ))
104-
105106 return k , d
106107 })
107108
@@ -119,9 +120,9 @@ func componentFunc(cliConfig schema.CliConfiguration, component string, stack st
119120 y , err2 := u .ConvertToYAML (outputMetaProcessed )
120121 if err2 != nil {
121122 u .LogError (err2 )
123+ } else {
124+ u .LogTrace (cliConfig , y )
122125 }
123- u .LogTrace (cliConfig , y )
124- u .LogTrace (cliConfig , "\n " )
125126 }
126127
127128 return sections , nil
0 commit comments