objective-cmacoscocoanspredicateeditor

NSPredicateEditor not handling integer values


I have a fairly simple NSPredicateEditor setup, and any String based predicates work fine, but integer predicates are causing an exception.

The predicate editor appears to be configured correctly…

enter image description here

…but whenever I choose one of those left hand values from the predicate editor, I get this exception, like the predicate editor is treating the number as a string:

2016-10-29 10:48:12.416 PredicateBarTesting[29041:303] -[__NSCFNumber length]: unrecognized selector sent to instance 0x37 2016-10-29 10:48:12.419 PredicateBarTesting[29041:303] An uncaught exception was raised

Full exception: http://d.pr/n/XT97

Any ideas?

Source code: http://d.pr/f/Ng2l


Solution

  • The left expressions in the predicate editor row template shoud be 'Keypaths' instead of 'Contant Values' (strings).