@@ -86,22 +86,23 @@ func componentFunc(cliConfig schema.CliConfiguration, component string, stack st
86
86
y , err2 := u .ConvertToYAML (outputMeta )
87
87
if err2 != nil {
88
88
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 ))
89
91
}
90
- u .LogTrace (cliConfig , fmt .Sprintf ("\n Result of 'atmos terraform output %s -s %s' before processing it:\n %s\n " , component , stack , y ))
91
92
}
92
93
93
94
outputMetaProcessed := lo .MapEntries (outputMeta , func (k string , v tfexec.OutputMeta ) (string , any ) {
94
95
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 ))
96
97
97
98
d , err2 := u .ConvertFromJSON (s )
98
99
99
100
if err2 != nil {
100
101
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 ))
101
104
}
102
105
103
- u .LogTrace (cliConfig , fmt .Sprintf ("Converted the variable %s from JSON to string representation.\n Result: %s\n " , s , d ))
104
-
105
106
return k , d
106
107
})
107
108
@@ -119,9 +120,9 @@ func componentFunc(cliConfig schema.CliConfiguration, component string, stack st
119
120
y , err2 := u .ConvertToYAML (outputMetaProcessed )
120
121
if err2 != nil {
121
122
u .LogError (err2 )
123
+ } else {
124
+ u .LogTrace (cliConfig , y )
122
125
}
123
- u .LogTrace (cliConfig , y )
124
- u .LogTrace (cliConfig , "\n " )
125
126
}
126
127
127
128
return sections , nil
0 commit comments