Skip to content

Conversation

@daescha
Copy link
Contributor

@daescha daescha commented Nov 22, 2025

  • fix plugin icons not showing when buiilding with mob
  • gate yaml import to only happen when the code using it is executed, to prevent users who check out this repo before a new release of mo happens from running into issues with that
  • bail out of mapping function early if no mods to prevent failures because of that
  • correct spacing in generated modsettings file (nodes not indented enough)
  • gate diffing of modsettings for only if files exist and debug is enabled
  • exec 2 of the dialog boxes created in lslib updated so they are actually shown
  • add conversion of yamls in bin folder to create a consistent experience with the other folders, even though this one doesnt get mapped to documents dir
  • mv files named 'log.txt' in Mods folders to logs dir when done
  • remove empty folders left behind by plugin in the documents dir
  • ensure all directories are created when needed
  • add a small sleep after generating modsettings to ensure it gets picked up by the executable
  • create dirs that should be sent to the overwrite folder from the docs folder if they dont exist in the overwrite folder when mapping starts

daescha and others added 16 commits November 21, 2025 17:22
… a function to share the creating of the xml strings for ModuleShortDesc
…ocuments folder if they dont exist in the mapping function, log all directories mapped if debug is enabled
@daescha
Copy link
Contributor Author

daescha commented Nov 22, 2025

@spectrbro @TheForgotten69 as the only users I know of of the bg3 plugin, id be interested in your thoughts on these changes, if you have some time. Thanks 🤝

@daescha
Copy link
Contributor Author

daescha commented Nov 26, 2025

@Holt59 this is ready for review.

@TheForgotten69
Copy link
Contributor

I will test more thoroughly but so far:

  • I can check updates for mods, it no longer crash directly
  • If the mod list is too big, it still crashes so

I never really dig into what was the root cause but it seems that this MR mitigates this but don't entirely fix it. Not sure if there are logs I can dig/share regarding this @daescha

@daescha
Copy link
Contributor Author

daescha commented Dec 2, 2025

I will test more thoroughly but so far:

  • I can check updates for mods, it no longer crash directly
  • If the mod list is too big, it still crashes so

How big are we talking @TheForgotten69 ? i have it working with 300+ mods just fine.

@TheForgotten69
Copy link
Contributor

TheForgotten69 commented Dec 2, 2025

I will test more thoroughly but so far:

  • I can check updates for mods, it no longer crash directly
  • If the mod list is too big, it still crashes so

How big are we talking @TheForgotten69 ? i have it working with 300+ mods just fine.

I have ~450 mods including textures that were auto converted, not sure what is the culprit though. I think it tries to do some operation and crashes.
i'm using ModOrganizer v2.5.3b2 for reference

@daescha
Copy link
Contributor Author

daescha commented Dec 3, 2025

@TheForgotten69 a stacktrace or any further context (crash message, or just log messages immediately before crash) on the crash would help. Might be a stacktrace in mo_interface.log. I cant think of any reason itd be able to handle 300 mods but not 450, so definitely will need that context to solve anything.

@TheForgotten69
Copy link
Contributor

Okay the log isn't that helpful sadly:

[2025-12-03 22:36:29.293 D] command line: '"D:\Games\Modding\MO2\ModOrganizer.exe" '
[2025-12-03 22:36:29.293 I] starting Mod Organizer version 2.5.3-beta.2 revision 2e1e4bbc in D:/Games/Modding/MO2, usvfs: 0.5.7.0
[2025-12-03 22:36:29.293 I] data path: C:/Users/USERNAME/AppData/Local/ModOrganizer/Baldur's Gate 3
[2025-12-03 22:36:29.293 I] working directory: D:/Games/Modding/MO2
[2025-12-03 22:36:29.293 D] timing: MOApplication setup() 1 ms
[2025-12-03 22:36:51.403 I] using game plugin 'Baldur's Gate 3' ('baldursgate3', variant (none), steam id '1086940') at D:/Games/SteamLibrary/steamapps/common/Baldurs Gate 3
[2025-12-03 22:36:55.843 E] ModOrganizer has crashed, core dump created.

And it's with the maximum logging level. It only occurs with this extension, the previous I used/all the other games worked fine.

The crash dump is also unhelpful:

0:000> !analyze -v
*******************************************************************************
*                                                                             *
*                        Exception Analysis                                   *
*                                                                             *
*******************************************************************************


KEY_VALUES_STRING: 1

    Key  : Analysis.CPU.mSec
    Value: 30953

    Key  : Analysis.Elapsed.mSec
    Value: 31352

    Key  : Analysis.IO.Other.Mb
    Value: 1

    Key  : Analysis.IO.Read.Mb
    Value: 4

    Key  : Analysis.IO.Write.Mb
    Value: 216

    Key  : Analysis.Init.CPU.mSec
    Value: 141765

    Key  : Analysis.Init.Elapsed.mSec
    Value: 306177

    Key  : Analysis.Memory.CommitPeak.Mb
    Value: 607

    Key  : Analysis.Version.DbgEng
    Value: 10.0.29457.1000

    Key  : Analysis.Version.Description
    Value: 10.2506.23.01 amd64fre

    Key  : Analysis.Version.Ext
    Value: 1.2506.23.1

    Key  : CLR.BuiltBy
    Value: NET481REL1LAST_25H2

    Key  : CLR.Engine
    Value: CLR

    Key  : CLR.Version
    Value: 4.8.9221.0

    Key  : Failure.Bucket
    Value: BREAKPOINT_80000003_dbgcore.dll!TraceLoggingRegister_EventRegister_2U__PERF__

    Key  : Failure.Exception.Code
    Value: 0x80000003

    Key  : Failure.Hash
    Value: {bd5582ca-e8b1-9144-2d35-3b2243fdcd98}

    Key  : Failure.ProblemClass.Primary
    Value: BREAKPOINT

    Key  : Faulting.IP.Type
    Value: Null

    Key  : Timeline.OS.Boot.DeltaSec
    Value: 162586

    Key  : Timeline.Process.Start.DeltaSec
    Value: 79

    Key  : WER.OS.Branch
    Value: ge_release

    Key  : WER.OS.Version
    Value: 10.0.26100.1

    Key  : WER.Process.Version
    Value: 2.5.3.0


FILE_IN_CAB:  ModOrganizer-2.5.3-beta.2-20251203T222935.dmp

NTGLOBALFLAG:  0

EXCEPTION_RECORD:  (.exr -1)
ExceptionAddress: 0000000000000000
   ExceptionCode: 80000003 (Break instruction exception)
  ExceptionFlags: 00000000
NumberParameters: 0

FAULTING_THREAD:  adc4

PROCESS_NAME:  ModOrganizer.exe

ERROR_CODE: (NTSTATUS) 0x80000003 - {EXCEPTION}  Breakpoint  A breakpoint has been reached.

EXCEPTION_CODE_STR:  80000003

STACK_TEXT:  
000000fc`2d8f7b88 00007ffb`f5530108     : 00000000`00000000 00007ffc`1b7b148d ffffffff`ffffffff 00007ffc`1b7e7e51 : ntdll!NtGetContextThread+0x14
000000fc`2d8f7b90 00000000`00000000     : 00000000`00000000 00000000`00000000 00000000`00000000 00000000`00000000 : dbgcore!TraceLoggingRegister_EventRegister_2U <PERF> (dbgcore+0x108)


STACK_COMMAND: ~0s; .ecxr ; kb

SYMBOL_NAME:  dbgcore!TraceLoggingRegister_EventRegister_2U <PERF> +25801ac6170

MODULE_NAME: dbgcore

IMAGE_NAME:  dbgcore.dll

FAILURE_BUCKET_ID:  BREAKPOINT_80000003_dbgcore.dll!TraceLoggingRegister_EventRegister_2U__PERF__

OS_VERSION:  10.0.26100.1

BUILDLAB_STR:  ge_release

OSPLATFORM_TYPE:  x64

OSNAME:  Windows 10

IMAGE_VERSION:  6.2.26100.7019
FAILURE_ID_HASH:  {bd5582ca-e8b1-9144-2d35-3b2243fdcd98}
Followup:     MachineOwner

@daescha
Copy link
Contributor Author

daescha commented Dec 7, 2025

@TheForgotten69 yeah that stack trace is useless (to me, at least: im not well versed in reading core dumps) unfortunately. Heres how I would debug if I had this issue: go through the code and comment out functionality until you can get it to launch, then work backward to find where the crash is happening. Its probably during the initialization phase.

I will test more thoroughly but so far:

I can check updates for mods, it no longer crash directly
If the mod list is too big, it still crashes so

have you tried reducing the number of mods to find out what that limit is?

@MeifanuQAQ
Copy link

Hello,

I'm writing to report an issue with the MO2 plugin for Baldur's Gate 3. When using MO2 version 2.5.2, the plugin fails to detect Baldur's Gate 3—the game does not appear in the selectable games list. This doesn't seem to be an isolated issue, as others have experienced it as well, though the exact cause is unclear.

Interestingly, an alternative script from Nexus Mods (https://www.nexusmods.com/site/mods/807?tab=files) is able to detect the game normally, although that script currently has other issues.

On a related note, I noticed your team has successfully implemented file mapping and load order management for BG3. Would it be possible to create a similar MO2 support plugin for Divinity: Original Sin 2? I've actually made a script that allows MO2 to recognize and manage DOS2, but I still have to manually edit the modsettings.lsx file to handle load order—my attempts to map the MO2 mod list order automatically were unsuccessful. The mod structure for DOS2 is very similar to BG3, involving extracting meta.lsx from unpacked .pak files.

Thank you for your work and consideration.

@daescha
Copy link
Contributor Author

daescha commented Dec 21, 2025

If I had to guess I would say that the issue you are experiencing is due to not having the yaml library available locally @MeifanuQAQ. This pr makes it so the yaml library is only imported if the feature using it is enabled.

@Holt59 I think this should be merged to address these issues, as it will continue to be a problem until there is a new release of MO2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants