Jump to content
LaunchBox Community Forums

LB 13.16 - An error occurred while trying to import games: Object reference not set to an instance of an object.


SiriusVI
Go to solution Solved by faeran,

Recommended Posts

Recently I've been getting this error randomly, when deleting a platform or changing emulator settings:

image.thumb.png.6d1d9b22206886bc55cbe2bd997d02a8.png

Does anyone know what this is?


EDIT:
Please help, Launchbox is completely unusable. None of my backups (even from months back) work.

The complete error reads this:

 

Object reference not set to an instance of an object.

App:     LaunchBox
Version: 13.16
Theme:   Default
Type:    System.NullReferenceException
Site:    Void RunSupportedGlobal(System.Object, System.Object)
Source:  LaunchBox

   at Unbroken.LaunchBox.Windows.Desktop.MenuActions.DeletePlatformMenuAction.RunSupportedGlobal(Object , Object )
   at Unbroken.LaunchBox.Windows.Desktop.MenuActions.DeletePlatformMenuAction.OnSelect()
   at ParserPool.WriteInvalidCreator(Object , ParserPool )
   at Unbroken.LaunchBox.Windows.Desktop.MenuActions.DeletePlatformMenuAction.Go(String platformName, Window parent)
   at ProxyMap.WriteInvalidCreator(String platformName, Window parent, ProxyMap )
   at Unbroken.LaunchBox.Windows.Desktop.MenuActions.SidebarDeleteMenuAction.OnSelect()
   at ParserPool.WriteInvalidCreator(Object , ParserPool )
   at Unbroken.LaunchBox.Windows.Desktop.ContextMenus.SideBarMenu.<>c.CloneTransformerParams(Object sender, RoutedEventArgs args)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   at System.Windows.Controls.MenuItem.InvokeClickAfterRender(Object arg)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

Recent Log:

   18:33:49 Exception

EDIT 2:

Went back to version 13.14 and the error disappeared for now. Updated to 13.16 again and the error reappeared. I'm not sure about 13.15. I thought the error appeard there, too, but I just updated and now it's gone with 13.15. Maybe I misremembered.

EDIT 3:
Did some further testing. 13.15 works. 13.16 is definitely busted on my machine. Can't delete plafforms or change Emulator settings. =/

EDIT 4:
I think there might be two separate errors. On 13.16. I cannot delete platforms and change emulator settings and on 13.15 I get this error if I change the emulator of a platform, I can however delete platforms:

image.thumb.png.427b901ddec39cbc751c06f16cf95325.png

 

The Emulator crash has something to do with DOSBOX. If I have Games with "use dosbox" enabled and also have MS-DOS in my retroarch Associated Platforms, I get this crash.

EDIT 5:

Just set up a fresh install of Launchbox on another drive. Same error with 13.16 when editing the emulator settings for MS-DOS.

Link to comment
Share on other sites

  • SiriusVI changed the title to Strange Error: Object reference not set to an instance of an object

I'm making a new post here to keep it more orderly. I think I have now found the issue. It seems to be a larger issue with my emulator folder. All my emulators are located in "M:\Launchbox\Emulators"

What I have just found out is that if I rename my "Emulators" folder to something else ("Emulators_BACKUP"), I get no no more crashes with both 13.15 and 13.16 when deleting platforms, and so on.

So, the issue must be with something inside my emulators folder. Does anyone have any idea how to troubleshoot this?

EDIT: Wait a second, might this have something to do with symbolic links? I have various symbolic links in my emulators folder that point to directories on external drives. Could that be an issue? I don't know how to test this, because I have so many symbolic links and I don't want to delete them all. Also, I need those symlinks badly.

Any ideas?

EDIT 2:
More testing - Symlinks are probably not the problem. I tested JUST my retroarch emulator without Symlinks and the error still appeared. After removing retroarch again (empty emulators folder), everything worked again.

EDIT 3:
OK so the last Test I did for today was to move my Retroarch Emulator into a Folder outside of Launchbox and set the path in Launchbox to the new location of this emulator. The result is that when Retroarch is set up in Launchbox, there is the crash, if not, then not. Might this have something to do with the associated platforms? I have A LOT of them. What might be the error?

Edited by SiriusVI
Link to comment
Share on other sites

So I can definitely say that it has something to do with my main instance of RetroArch.

 

If I remove Retroarch from my Emulators Folder, the error does not appear. If Retroarch is present, the the error appears when deleting a platform. The associated platforms set in Launchbox for Retroarch have nothing to do with it I think. I deleted all associated platforms but one and the error was still there.

 

I still have to figure out what exactly causes it. If I make a new instance of RetroArch, the error is fixed, but I have a very thorough setup for many cores, and I just can't start from scratch.

 

Any ideas what in my Retroarch folder could cause this weird error when deleting a platform???

 

EDIT: the error does not appear in 13.14. Maybe there was a change made that messed something up with my system? Tje plugins that update the Emulators? Or the new save feature?

Edited by SiriusVI
Link to comment
Share on other sites

OK, so after hours of testing, I think I finally found the solution:

I had a few title updates and DLC for citra installed to an external HDD and then created Symbolic Links from "M:\Launchbox\Emulators\RetroArch\saves\Citra\Citra" to the place on my external HDD. The HDD however is not connected to the PC at all times, to increase its longevity. My errors completely disappeared once I deleted the symlinks and for now it's stable again.

I only recently remembered that I had created these symlinks, that's why I previously thought symlinks were not to blame, but I believe they definitely are.

Now the question is why this problem occurs in 13.15 and 13.16. Could this be related to the Emulator Update Plugins and the new Saves Feature? Also, What can I do about it. I need to keep the symlinks, because I'd run out of space without them =/.

Link to comment
Share on other sites

Just to report the same error since the last update...

When I try to add a game, I've got that error :

"An error occurred while trying to import games: Object reference not set to an instance of an object."

So I suspect some "bug" somewhere maybe with the new update

2024-09-16 17_31_10-LaunchBox.jpg

Edited by StarflashW666
Link to comment
Share on other sites

Yeah well from my understanding (which is very limited of course), this error results because Launchbox wants to write something somewhere where it has no access for whatever reason. In my case it (probably) was because I had Symlinks that lead nowhere.

I don't know what might be wrong in your case. It happened with the katest update for you, too?

Edited by SiriusVI
Link to comment
Share on other sites

  On 9/16/2024 at 6:42 PM, SiriusVI said:

Yeah well from my understanding (which is very limited of course), this error results because Launchbox wants to write something somewhere where it has no access for whatever reason. In my case it (probably) was because I had Symlinks that lead nowhere.

I don't know what might be wrong in your case. It happened with the katest update for you, too?

Expand  

I just reported them the bug. It's so annoying. And yeah,  the error is since the latest 13.16 update for me as well. I haven’t changed anything at all in my configuration tho. I just updated and now I got that bug. Will investigate too on my side. I'll let you know if I find anything. ;) 

Link to comment
Share on other sites

I have been having the same issue as Starflash with the new update. If I try to import/copy the roms, I get the same error message. Even when I drag some roms into the game folder with LB open, LB doesn't even pick them up anymore. Only thing I found that works so far is to put them in my game folder and use Tools/Scan/For Added Roms. Then it finds them and updates everything. I haven't changed anything on my PC and it was working fine in the last versions of LB so I haven't a clue. 

  • Like 2
Link to comment
Share on other sites

  On 9/16/2024 at 10:27 PM, CKID said:

I have been having the same issue as Starflash with the new update. If I try to import/copy the roms, I get the same error message. Even when I drag some roms into the game folder with LB open, LB doesn't even pick them up anymore. Only thing I found that works so far is to put them in my game folder and use Tools/Scan/For Added Roms. Then it finds them and updates everything. I haven't changed anything on my PC and it was working fine in the last versions of LB so I haven't a clue. 

Expand  

Well, I see I'm not the only one. For the record, I used that same method as you first, and it initially worked for a few imports, but now even that method is completely failing. I just can't import any games anymore whatever I try, I keep getting this error message. Arrrrrgh!

Link to comment
Share on other sites

So far its working its working for me now.I didn't get a chance to test it last night and I figured it was still messed up today. I first tried importing like 3 roms then 25 roms and LB moved them to my game folder but I don't know how long it will last like you said. Guess I'll keep adding them to see if the error comes back or not.

  • Like 1
Link to comment
Share on other sites

I'll be working tomorrow almost exclusively on this issue. If anyone could provide the following bits of information it'd be very helpful in determining the cause of the issue!

1) Is the location your importing from on the same drive as the LaunchBox install?
2) Is the location your importing from IN the LaunchBox folder?
3) What import method are you using to import your games? Import wizard, drag/drop, something else?
4) What folder is the games folder of the platform you're importing games to? Does that folder actually exist?
5) What platform are you importing for? What is it's scrape as value set as if not a default platform name?

  • Like 2
Link to comment
Share on other sites

same problem here after the new update , before it all worked fine , for me i have all folders with games/emulators inside launchbox folder and i just drag drop roms to launchbox and always worked fine , in these days only tried importing psp stuff using ppsspp emulator , probably it happen also with other systems but not had tried with them , hope can be fixed soon , thanks

  • Like 1
Link to comment
Share on other sites

FYI, I think the issue is due to the link between the games/platforms and the associated emulators. So I unchecked all the associations boxes, closed, then reopened and rechecked every associations. It appear to be working now... Let's see if it stays that way, fingers crossed. ;) 
PS : I’m not an expert and I’m not saying the issue comes from here, it's just that this solution seems to work for me... for now....

Link to comment
Share on other sites

  On 9/17/2024 at 2:53 AM, C-Beats said:

I'll be working tomorrow almost exclusively on this issue. If anyone could provide the following bits of information it'd be very helpful in determining the cause of the issue!

1) Is the location your importing from on the same drive as the LaunchBox install?
2) Is the location your importing from IN the LaunchBox folder?
3) What import method are you using to import your games? Import wizard, drag/drop, something else?
4) What folder is the games folder of the platform you're importing games to? Does that folder actually exist?
5) What platform are you importing for? What is it's scrape as value set as if not a default platform name?

Expand  

1) Yes, same drive under same letter R:\, external drive.
2) No, I import the roms from the C:\ telling Launchbox to automatically move those roms in the correct folder.
3) Drap/Drop mostly, but even wizard didn't work.
4) All folders are named the same way as the platforms, Launchbox created them itself in the first place, and yes, all folders actually exist.
5) So many platforms (Commodore 64, Game Boy, PS1, etc etc), but anyway, none of them work(ed).  Scraps are "by default" for all platforms.

PS: I just wrote a post below to explain how I (maybe) solved my problem....

Thx

Link to comment
Share on other sites

  On 9/17/2024 at 1:58 PM, C-Beats said:

Can you all turn on Debug Logging via Options and get that error to pop and then send the log file generated? Curious if it has more information we can use to track down the cause.

Expand  

I'm having the same issue as everyone here after updating to 13.16. I don't have the error in 13.15. The error is random, like 60% chance it will happen.

Debug 2024-09-17 08-11-11 PM.logFetching info...

Link to comment
Share on other sites

I've been experiencing the same issue ever since the upgrade. My workaround to adding games at the moment is to turn debugging on/off (depending on what it's currently set to) and try importing the game again (that works).

 

1) Is the location your importing from on the same drive as the LaunchBox install? No, games are on an external drive.  Launchbox/Emulators are on the internal drive.
2) Is the location your importing from IN the LaunchBox folder? No, games are on an external drive
3) What import method are you using to import your games? Import wizard, drag/drop, something else? Import Wizard
4) What folder is the games folder of the platform you're importing games to? Does that folder actually exist? Yes. These folders have existed for years and haven't had a problem until the new release.
5) What platform are you importing for? What is it's scrape as value set as if not a default platform name? Had the issue on 3 games I've tried importing since the update (PSP, Neo Geo CD & Arcade).

Link to comment
Share on other sites

I've just received another one of these errors, after I restored soem of my symlinks (with the external drive attatched, so the symlinks were acessible) It happened when I tried to edit my "MS-DOS" platform I wanted to change the "parent" category.

image.thumb.png.0e4dd25a491aaef22c1ce7ba6c9b8a42.png

 

(Inner Exception)

Object reference not set to an instance of an object.

App:     LaunchBox
Version: 13.16
Theme:   Default
Type:    System.NullReferenceException
Site:    Void PopTransformerAnnotation(System.Collections.Generic.List`1[System.String])
Source:  LaunchBox

   at Unbroken.LaunchBox.Windows.Desktop.ViewModels.AddEditPlatformViewModel.PopTransformerAnnotation(List`1 i)
   at ResolverCreator.WriteInvalidCreator(Object , List`1 i, ResolverCreator )
   at Unbroken.LaunchBox.Windows.Desktop.ViewModels.AddEditPlatformViewModel.Save()


(Outer Exception)

Exception has been thrown by the target of an invocation.

App:     LaunchBox
Version: 13.16
Theme:   Default
Type:    System.Reflection.TargetInvocationException
Site:    System.Object InvokeMethod(System.Object, System.Span`1[System.Object] ByRef, System.Signature, Boolean, Boolean)
Source:  System.Private.CoreLib

   at System.RuntimeMethodHandle.InvokeMethod(Object target, Span`1& arguments, Signature sig, Boolean constructor, Boolean wrapExceptions)
   at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
   at Caliburn.Micro.ActionMessage.<>c.<.cctor>b__33_0(ActionExecutionContext context)
   at Caliburn.Micro.ActionMessage.Invoke(Object eventArgs)
   at System.Windows.Interactivity.TriggerBase.InvokeActions(Object parameter)
   at System.Windows.Interactivity.EventTriggerBase.OnEvent(EventArgs eventArgs)
   at System.Windows.Interactivity.EventTriggerBase.OnEventImpl(Object sender, EventArgs eventArgs)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   at System.Windows.Controls.Primitives.ButtonBase.OnClick()
   at System.Windows.Controls.Button.OnClick()
   at System.Windows.Controls.Primitives.ButtonBase.OnMouseLeftButtonUp(MouseButtonEventArgs e)
   at System.Windows.UIElement.OnMouseLeftButtonUpThunk(Object sender, MouseButtonEventArgs e)
   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.ReRaiseEventAs(DependencyObject sender, RoutedEventArgs args, RoutedEvent newEvent)
   at System.Windows.RoutedEventArgs.InvokeHandler(Delegate handler, Object target)
   at System.Windows.EventRoute.InvokeHandlersImpl(Object source, RoutedEventArgs args, Boolean reRaised)
   at System.Windows.UIElement.RaiseEventImpl(DependencyObject sender, RoutedEventArgs args)
   at System.Windows.UIElement.RaiseTrustedEvent(RoutedEventArgs args)
   at System.Windows.Input.InputManager.ProcessStagingArea()
   at System.Windows.Input.InputProviderSite.ReportInput(InputReport inputReport)
   at System.Windows.Interop.HwndMouseInputProvider.ReportInput(IntPtr hwnd, InputMode mode, Int32 timestamp, RawMouseActions actions, Int32 x, Int32 y, Int32 wheel)
   at System.Windows.Interop.HwndMouseInputProvider.FilterMessage(IntPtr hwnd, WindowMessage msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at System.Windows.Interop.HwndSource.InputFilterMessage(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndWrapper.WndProc(IntPtr hwnd, Int32 msg, IntPtr wParam, IntPtr lParam, Boolean& handled)
   at MS.Win32.HwndSubclass.DispatcherCallbackOperation(Object o)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

Recent Log:

   07:30:16 Exception


And on top of that, I just got this error as well, which I never got before:

image.png.df11b0220538a8993b1e051cc9aa4cf3.png

Trying to import roms from an external drive, keeping the roms in their current location (not automoving them toi the Launchbox directory).

The errors go away once I delete my symblic links again. There seems to be a serious issue with symlinks.

Edited by SiriusVI
  • Like 1
Link to comment
Share on other sites

seems the error happen if a system is on reatroarch too even if not checkmarked as default and using also a stand alone emulator , tried importing a ps2 game which system core is not on retroarch and worked , psp istead still give error and retroarch have a psp core , hope this can help fix this issue , is very annoying , thanks

 

nevermind , it still give error , like another guy said here

 , it worked only because ive waited some minutes before importing , weird issue

Edited by DanielHogan
  • Like 1
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...