on a compiled app, one of my customer gets this error sometimes. I’ve never seen it in a debug app.
what can it come from ?
thanks.
this error is inside a compiled xojo app I made, this part is certainly inside the xojo framework, which I have no access at all ! only people from xojo team or people making xojo plugins may have an answer to my question …
My apps have no plugin except the postgres and mysql database.
Then you will see that you will be able to solve the problem. Good luck and sorry for the inconvenience
This looks like a failed assertion in the Xojo framework. The variable imp is nil.
That usually means the implementation c++ object was not created or freed too early.
It can happen when App is compiled for older macOS and run in recent one.
With which Xojo version was this compiled?
My guess… compiled with an older Xojo version and your customer runs the latest macOS version. Seen that before.
compiled with xojo 2024r31, and customer is on sonoma or sequoia I don’t recall. I will soon deliver an update with xojo 2024r41, will see
did you get this exact same error message yourself ?
What version of macOS?
I don’t recall but the customer has a recent macbook. so sonoma or sequoia.
So it could be that you’re using a feature that no longer exists in the SDK. Could you give a list of the items in your toolbar including the non-button items?
I’m pretty sure that Apple deprecated separators a while ago, but I’d expect you to get that assertion immediately every time if it was totally gone.
I’m just thinking that this separator does nothing here …
will try to remove it and see how it goes.
thanks Greg.
Just don’t understand why more than 10 users have this app, and only one gets the error from time to time !
all users have recent mac and systems.
You would need more data. It’s possible that the affected system has a text encoding that you didn’t plan for or right to left text or something odd like that.
Oh hey, do you add and remove items from this toolbar at runtime?
no I just hide or display some .
Aha! So… in the macOS SDK, there’s no such thing as a hidden toolbar item. Under the hood, the items are physically removed from the list of items on the bar when you hide them and then added back onto that list when you make them visible.
So it could be that these users are getting caught in the limbo somehow between taking an action and the item being hidden/removed. The item being removed might cause the equivalent of a nilobjectexception in the Xojo framework if it was then accessed by another part of the framework.
I don’t understand why because I hide/show them at the opening of the window
there are no dynamic hide/show during the user time.
more information, sometimes the customer gets a macos error. here is the dump.
Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0 XojoFramework 0x1042109c8 ToolbarImpCocoa::_ItemForIdentifier(NSToolbar*, NSString*, bool) + 132
1 AppKit 0x199fcf038 -[NSToolbar _newItemFromDelegateWithItemIdentifier:propertyListRepresentation:willBeInsertedIntoToolbar:] + 268
2 AppKit 0x199fccdc8 -[NSToolbar _newItemFromItemIdentifier:propertyListRepresentation:requireImmediateLoad:willBeInsertedIntoToolbar:] + 304
3 AppKit 0x199fcebe0 -[NSToolbar _loadAllPlaceholderItems] + 292
4 AppKit 0x199fdd248 -[NSToolbar items] + 36
5 AppKit 0x199fdcd70 -[NSToolbarView _syncItemSet] + 84
6 AppKit 0x19a984b2c -[NSToolbarView _syncItemSetAndUpdateItemViewersWithSEL:setNeedsModeConfiguration:setNeedsDisplay:updateKeyLoop:] + 48
7 AppKit 0x199fce5d4 -[NSToolbarView setToolbar:] + 280
8 AppKit 0x19a982fb4 +[NSToolbarView newViewForToolbar:inWindow:] + 88
9 AppKit 0x199fcd97c -[NSToolbar _loadViewIfNecessary] + 108
10 AppKit 0x199fcd8ac -[NSToolbar _windowWillShowToolbar] + 68
11 AppKit 0x199fcd7f4 -[NSWindow _showToolbar:animate:] + 128
12 AppKit 0x199fcd704 -[NSToolbar _show:animate:] + 92
13 AppKit 0x199fcd670 -[NSToolbar _toggleShown:animate:] + 88
14 AppKit 0x199fca818 -[NSWindow setToolbar:] + 396
15 XojoFramework 0x10420fb74 ToolbarImpCocoa::ToolbarImpCocoa(ToolbarControl*, xojo::Rect<xojo::Points>) + 516
16 XojoFramework 0x10423a300 ToolbarImp::New(ToolbarControl*, xojo::Rect<xojo::Points>) + 76
17 XojoFramework 0x104238dec ToolbarCreatePane + 60
18 Sollo-Gestion 0x1010bd634 Toolbar.Event_CreatePane%%o<Toolbar> + 36
19 XojoFramework 0x104273d4c CreateNewControlPane(RuntimeControl*) + 116
20 XojoFramework 0x1042742cc RuntimeViewWindow::RuntimeViewWindow(RuntimeView*, Window::WindowType, double) + 780
21 XojoFramework 0x104273190 CreateStandAloneWindow(RuntimeView*, RuntimeView*) + 304
22 XojoFramework 0x104386e28 RuntimeCreateWindow + 924
23 Sollo-Gestion 0x10100fe90 Window.__Init%%o<Window> + 40
24 XojoFramework 0x104370f4c 0x1040fc000 + 2576204
25 XojoFramework 0x104370f4c 0x1040fc000 + 2576204
26 XojoFramework 0x104370f4c 0x1040fc000 + 2576204
27 XojoFramework 0x104370d7c RuntimeNewObject + 304
@Greg_O if this make some sens to you ?