In my App I work with a "tree" structure (nested NSArrays and NSDictionaries) and have stored them in the file system using NSPropertyListSerialization, which always works fine.
In general loading the same structure via NSPropertyListSerialization works fine too, but if the "tree" is getting larger (nested deeper), NSPropertyListSerialization can no longer read the file (even if it was able to saved it without error before).
It will fail with the error "Too many nested arrays or dictionaries".
The issue seems to be the nesting level, not the general amount of nodes in the property list, because the file itself is very small (about 50 KB) .
I've never seen this in the past, so this might be a new issue of iOS 14.
So my question is: is there another way to read the propertylist file? The problem is that the file is stored in the binary format (not the plain XML format), so just using a general XML parser is not an option, the binary file format seems to be undocumented by Apple.
In general loading the same structure via NSPropertyListSerialization works fine too, but if the "tree" is getting larger (nested deeper), NSPropertyListSerialization can no longer read the file (even if it was able to saved it without error before).
It will fail with the error "Too many nested arrays or dictionaries".
The issue seems to be the nesting level, not the general amount of nodes in the property list, because the file itself is very small (about 50 KB) .
I've never seen this in the past, so this might be a new issue of iOS 14.
So my question is: is there another way to read the propertylist file? The problem is that the file is stored in the binary format (not the plain XML format), so just using a general XML parser is not an option, the binary file format seems to be undocumented by Apple.
I hope you will find useful information here. It notably details Binary plist structure.
https ://medium. com/@karaiskc/understanding-apples-binary-property-list-format-281e6da00dbd
Have you tried to read the binary in a text editor ?
Note: the article dates 2018, so not iOS 14. So there may have been some changes, but I assume (hope) it has remained essentially the same.
Good luck. Thanks to feedback.
https ://medium. com/@karaiskc/understanding-apples-binary-property-list-format-281e6da00dbd
Have you tried to read the binary in a text editor ?
Note: the article dates 2018, so not iOS 14. So there may have been some changes, but I assume (hope) it has remained essentially the same.
Good luck. Thanks to feedback.