Closed phillfarrugia closed 6 years ago
@matthewpalmer Ah! A colleague of mine investigated further and we've discovered this is the cause of the issue I was experiencing, not actually Locksmith itself.
For reference, Xcode 9 requires Unit Tests to be connected to an App Target as Host in order to access the keychain https://stackoverflow.com/questions/46299406/reading-from-keychain-xcode-9-simulators-returns-nothing
Even though the project compiles within Swift 4, I suspect that there are some underlying issues causing unexpected behavior when writing/reading from the keychain.
In a project that uses Locksmith, calling try
Locksmith.saveData(data:forUserAccount:inService:)
is throwing aparam
error.From my investigations into why this might be occurring the source of the error is in Locksmith.swift line 559-565. I suspect it may be being caused by the use of $0 to pass a closure parameter value into another closure. If I understand correctly Swift 4.0 does introduce some changes to this syntax?
Thanks