UIDocument save error: Could not get attribute values - ios

I see this error in Xcode debug console when I call save(...) on my UIDocument, but it seems to have no effect on my app. Anyone know what causes it and how to stop it? I'm saving documents as a package with FileWrapper.
2018-08-12 10:24:12.818324-0400 MyApp[2694:1486251] [default] [ERROR]
Could not get attribute values for item /private/var/[...]/Documents/NewDoc.myextension (s).
Error: Error Domain=LocalStorageFileProvider.LocalFileProviderError Code=0 "(null)"

Related

NSPersistentCloudKitContainer error handling

Sometimes an NSPersistentCloudKitContainer will report an error in the console like so:
*2020-04-14 16:41:27.725794+0100 ExampleApp[9736:8226377] [error] error: CoreData+CloudKit: -: <NSCloudKitMirroringDelegate: 0x282b944d0>: Sending ‘NSCloudKitMirroringDelegateWillResetSyncNotificationName’ with reason: ‘UserPurgedZone’* [NSCloudKitMirroringDelegate logResetSyncNotification:](1798)
In my code I have error handling in the loading of the persistent store but this error doesn't trigger it as this error comes after the store has loaded.
Where do I handle these errors? How can I see these errors in code?

Xcode Crash due to Persistance container in swift

I'm currently making an app implementing core data. However, when I build, it crashes at this line:
Thread 1: Fatal error: Unresolved error Error
Domain=NSCocoaErrorDomain Code=134140 "Persistent store migration
failed, missing mapping model."
UserInfo={sourceModel=() isEditable
0, entities {
What does this mean? How can I solve this?

What is "I/O error 1785"?

I am getting "I/O error "1785" in my program in
Vcl.FileCtrl.TDirectoryListBox.SetDirectory ->
Vcl.FileCtrl.ProcessPath
I cannot find a description in Delphi's Help for this.
From the help file:
All errors other than I/O errors and fatal errors are reported with the error codes returned by the operating system.
As all of the listed I/O errors are in the 100..106 range, and the fatal errors are all in 200..232, it stands to reason that this is an OS error, and SysErrorMessage(1785) would give you a description of the error:
The disk media is not recognized. It may not be formatted.
The actual error is ERROR_UNRECOGNIZED_MEDIA (thanks to #JoachimIsaksson for looking it up so I didn't have to do so).

Why on Xcode console I have to print object twice to print it correctly?

Suppose that I set up the breakpoint at some point of my code. I run the compiler, and app stop exactly there where i set up the breakpoint. Now I need to print object in console using, for instance:
po messageIdentifier
But instead of correct object i get a lot of errors:
error: Error in auto-import:
failed to get module 'Module-Name' from AST context:
...
A fatal parse error has occurred.
LLDB may become unstable; please restart your debug session as soon as possible.
but when i try to tap po messageIdentifier second time, the I get correct answer:
"44540ef4-7343-4cd6-89a2-a4ea97048d6f"
Why do I have to do this twice?

strict.lua - How do find out where the error occurred?

I am using strict.lua in a cocos2d-x project under Xcode. When I get an error it doesn't tell me where the error occurred. I just get an error message like:
cocos2d: LUA ERROR: attempt to call a number value
PANIC: unprotected error in call to Lua API (...<folder>/strict.lua:30: attempt to index a nil value)
How can I get strict.lua to tell me where the error occurred or give me a call stack?
(Note putting print(debug.traceback()) in strict.lua doesn't work)

Resources