MakeAWishFoundation/SwiftyMocky

SwiftTemplate cannot convert value of type 'AttributeList' error

reejosamuel opened this issue · 0 comments

Getting this error. I have tried reinstalling it a few times. Looking for any hints to resolve this issue:

This is on an M1 machine if that matters.
Running the following swift version:

swift-driver version: 1.62.8 Apple Swift version 5.7 (swiftlang-5.7.0.127.4 clang-1400.0.29.50)
Target: arm64-apple-macosx12.0
Scanning sources...
Found 340 types in 215 files, 124 changed from last run.
Loading templates...
Loaded 1 templates.
Generating code...
error: [0/1] Planning build
Building for debugging...
[1/40] Compiling SourceryRuntime Protocol.swift
[2/40] Compiling SourceryRuntime ProtocolComposition.swift
[3/40] Compiling SourceryRuntime Struct.swift
[4/40] Compiling SourceryRuntime Subscript.swift
[5/44] Compiling SourceryRuntime Typealias.swift
[6/44] Compiling SourceryRuntime Typed.generated.swift
[7/44] Compiling SourceryRuntime Typed.swift
[8/44] Compiling SourceryRuntime Variable.swift
[9/44] Compiling SourceryRuntime TemplateContext.swift
[10/44] Compiling SourceryRuntime Tuple.swift
[11/44] Compiling SourceryRuntime Type.swift
[12/44] Compiling SourceryRuntime TypeName.swift
[13/44] Compiling SourceryRuntime Coding.generated.swift
[14/44] Compiling SourceryRuntime Composer.swift
[15/44] Compiling SourceryRuntime Definition.swift
[16/44] Compiling SourceryRuntime Description.generated.swift
[17/44] Compiling SourceryRuntime Attribute.swift
[18/44] Compiling SourceryRuntime AutoHashable.generated.swift
[19/44] Compiling SourceryRuntime BytesRange.swift
[20/44] Compiling SourceryRuntime Class.swift
[21/44] Compiling SourceryRuntime Closure.swift
[22/44] Compiling SourceryRuntime Log.swift
[23/44] Compiling SourceryRuntime Method.swift
[24/44] Compiling SourceryRuntime Modifier.swift
[25/44] Compiling SourceryRuntime PhantomProtocols.swift
[26/44] Compiling SourceryRuntime Generic.swift
[27/44] Compiling SourceryRuntime GenericRequirement.swift
[28/44] Compiling SourceryRuntime Import.swift
[29/44] Compiling SourceryRuntime JSExport.generated.swift
[30/44] Compiling SourceryRuntime Dictionary.swift
[31/44] Compiling SourceryRuntime Diffable.generated.swift
[32/44] Compiling SourceryRuntime Diffable.swift
[33/44] Compiling SourceryRuntime Documentation.swift
[34/44] Emitting module SourceryRuntime
[35/44] Compiling SourceryRuntime Enum.swift
[36/44] Compiling SourceryRuntime Equality.generated.swift
[37/44] Compiling SourceryRuntime Extensions.swift
[38/44] Compiling SourceryRuntime FileParserResult.swift
[39/44] Compiling SourceryRuntime AccessLevel.swift
[40/44] Compiling SourceryRuntime Annotations.swift
[41/44] Compiling SourceryRuntime Array+Parallel.swift
[42/44] Compiling SourceryRuntime Array.swift
[43/44] Compiling SourceryRuntime AssociatedType.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)[44/46] Emitting module SwiftTemplate
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
[45/46] Compiling SwiftTemplate main.swift
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:579:60: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        return Helpers.extractAttributes(from: self.method.attributes).replacingOccurrences(of: "mutating", with: "")
                                                           ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:579:60: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        return Helpers.extractAttributes(from: self.method.attributes).replacingOccurrences(of: "mutating", with: "")
                                                           ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1212:61: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        return Helpers.extractAttributes(from: self.wrapped.attributes)
                                                            ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1212:61: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        return Helpers.extractAttributes(from: self.wrapped.attributes)
                                                            ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1438:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        let value = Helpers.extractAttributes(from: self.variable.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1438:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        let value = Helpers.extractAttributes(from: self.variable.attributes)
                                                                  ^

❌  Error: ShellOut encountered an error
Status code: 3
Message: "[0/1] Planning build
Building for debugging...
[1/40] Compiling SourceryRuntime Protocol.swift
[2/40] Compiling SourceryRuntime ProtocolComposition.swift
[3/40] Compiling SourceryRuntime Struct.swift
[4/40] Compiling SourceryRuntime Subscript.swift
[5/44] Compiling SourceryRuntime Typealias.swift
[6/44] Compiling SourceryRuntime Typed.generated.swift
[7/44] Compiling SourceryRuntime Typed.swift
[8/44] Compiling SourceryRuntime Variable.swift
[9/44] Compiling SourceryRuntime TemplateContext.swift
[10/44] Compiling SourceryRuntime Tuple.swift
[11/44] Compiling SourceryRuntime Type.swift
[12/44] Compiling SourceryRuntime TypeName.swift
[13/44] Compiling SourceryRuntime Coding.generated.swift
[14/44] Compiling SourceryRuntime Composer.swift
[15/44] Compiling SourceryRuntime Definition.swift
[16/44] Compiling SourceryRuntime Description.generated.swift
[17/44] Compiling SourceryRuntime Attribute.swift
[18/44] Compiling SourceryRuntime AutoHashable.generated.swift
[19/44] Compiling SourceryRuntime BytesRange.swift
[20/44] Compiling SourceryRuntime Class.swift
[21/44] Compiling SourceryRuntime Closure.swift
[22/44] Compiling SourceryRuntime Log.swift
[23/44] Compiling SourceryRuntime Method.swift
[24/44] Compiling SourceryRuntime Modifier.swift
[25/44] Compiling SourceryRuntime PhantomProtocols.swift
[26/44] Compiling SourceryRuntime Generic.swift
[27/44] Compiling SourceryRuntime GenericRequirement.swift
[28/44] Compiling SourceryRuntime Import.swift
[29/44] Compiling SourceryRuntime JSExport.generated.swift
[30/44] Compiling SourceryRuntime Dictionary.swift
[31/44] Compiling SourceryRuntime Diffable.generated.swift
[32/44] Compiling SourceryRuntime Diffable.swift
[33/44] Compiling SourceryRuntime Documentation.swift
[34/44] Emitting module SourceryRuntime
[35/44] Compiling SourceryRuntime Enum.swift
[36/44] Compiling SourceryRuntime Equality.generated.swift
[37/44] Compiling SourceryRuntime Extensions.swift
[38/44] Compiling SourceryRuntime FileParserResult.swift
[39/44] Compiling SourceryRuntime AccessLevel.swift
[40/44] Compiling SourceryRuntime Annotations.swift
[41/44] Compiling SourceryRuntime Array+Parallel.swift
[42/44] Compiling SourceryRuntime Array.swift
[43/44] Compiling SourceryRuntime AssociatedType.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)[44/46] Emitting module SwiftTemplate
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
[45/46] Compiling SwiftTemplate main.swift
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:579:60: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        return Helpers.extractAttributes(from: self.method.attributes).replacingOccurrences(of: "mutating", with: "")
                                                           ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:579:60: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        return Helpers.extractAttributes(from: self.method.attributes).replacingOccurrences(of: "mutating", with: "")
                                                           ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1212:61: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        return Helpers.extractAttributes(from: self.wrapped.attributes)
                                                            ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1212:61: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        return Helpers.extractAttributes(from: self.wrapped.attributes)
                                                            ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1438:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        let value = Helpers.extractAttributes(from: self.variable.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1438:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        let value = Helpers.extractAttributes(from: self.variable.attributes)
                                                                  ^"
Output: "Using configuration file at '/Users/user/src/ios/Modules/Core/.mocky92FFF6E5-61B3-488C-9B8C-A97AA9919A84/.config.yml.tmp'
Scanning sources...
Found 340 types in 215 files, 124 changed from last run.
Loading templates...
Loaded 1 templates.
Generating code...
error: [0/1] Planning build
Building for debugging...
[1/40] Compiling SourceryRuntime Protocol.swift
[2/40] Compiling SourceryRuntime ProtocolComposition.swift
[3/40] Compiling SourceryRuntime Struct.swift
[4/40] Compiling SourceryRuntime Subscript.swift
[5/44] Compiling SourceryRuntime Typealias.swift
[6/44] Compiling SourceryRuntime Typed.generated.swift
[7/44] Compiling SourceryRuntime Typed.swift
[8/44] Compiling SourceryRuntime Variable.swift
[9/44] Compiling SourceryRuntime TemplateContext.swift
[10/44] Compiling SourceryRuntime Tuple.swift
[11/44] Compiling SourceryRuntime Type.swift
[12/44] Compiling SourceryRuntime TypeName.swift
[13/44] Compiling SourceryRuntime Coding.generated.swift
[14/44] Compiling SourceryRuntime Composer.swift
[15/44] Compiling SourceryRuntime Definition.swift
[16/44] Compiling SourceryRuntime Description.generated.swift
[17/44] Compiling SourceryRuntime Attribute.swift
[18/44] Compiling SourceryRuntime AutoHashable.generated.swift
[19/44] Compiling SourceryRuntime BytesRange.swift
[20/44] Compiling SourceryRuntime Class.swift
[21/44] Compiling SourceryRuntime Closure.swift
[22/44] Compiling SourceryRuntime Log.swift
[23/44] Compiling SourceryRuntime Method.swift
[24/44] Compiling SourceryRuntime Modifier.swift
[25/44] Compiling SourceryRuntime PhantomProtocols.swift
[26/44] Compiling SourceryRuntime Generic.swift
[27/44] Compiling SourceryRuntime GenericRequirement.swift
[28/44] Compiling SourceryRuntime Import.swift
[29/44] Compiling SourceryRuntime JSExport.generated.swift
[30/44] Compiling SourceryRuntime Dictionary.swift
[31/44] Compiling SourceryRuntime Diffable.generated.swift
[32/44] Compiling SourceryRuntime Diffable.swift
[33/44] Compiling SourceryRuntime Documentation.swift
[34/44] Emitting module SourceryRuntime
[35/44] Compiling SourceryRuntime Enum.swift
[36/44] Compiling SourceryRuntime Equality.generated.swift
[37/44] Compiling SourceryRuntime Extensions.swift
[38/44] Compiling SourceryRuntime FileParserResult.swift
[39/44] Compiling SourceryRuntime AccessLevel.swift
[40/44] Compiling SourceryRuntime Annotations.swift
[41/44] Compiling SourceryRuntime Array+Parallel.swift
[42/44] Compiling SourceryRuntime Array.swift
[43/44] Compiling SourceryRuntime AssociatedType.swift
error: emit-module command failed with exit code 1 (use -v to see invocation)[44/46] Emitting module SwiftTemplate
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
[45/46] Compiling SwiftTemplate main.swift
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1551:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
    let attributes: String = Helpers.extractAttributes(from: type.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:579:60: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        return Helpers.extractAttributes(from: self.method.attributes).replacingOccurrences(of: "mutating", with: "")
                                                           ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:579:60: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        return Helpers.extractAttributes(from: self.method.attributes).replacingOccurrences(of: "mutating", with: "")
                                                           ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1212:61: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        return Helpers.extractAttributes(from: self.wrapped.attributes)
                                                            ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1212:61: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        return Helpers.extractAttributes(from: self.wrapped.attributes)
                                                            ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1438:67: error: cannot convert value of type 'AttributeList' (aka 'Dictionary<String, Array<Attribute>>') to expected argument type '[String : Attribute]'
        let value = Helpers.extractAttributes(from: self.variable.attributes)
                                                                  ^
/private/var/folders/2t/rrklsqws4z541v7jz9mdmt8m0000gp/T/SwiftTemplate/1.8.0/Sources/SwiftTemplate/main.swift:1438:67: note: arguments to generic parameter 'Value' ('[Attribute]' and 'Attribute') are expected to be equal
        let value = Helpers.extractAttributes(from: self.variable.attributes)
                                                                  ^