Story Compilation Error DOS2: All 8 Fixes for Divinity: Original Sin 2
The story compilation error DOS2 appears when Divinity: Original Sin 2 cannot build a Story file. The game fails to process your active mods properly.
This error produces three different message variants. Consequently, it can permanently wipe your journals. Different scenarios require different solutions. All verified fixes exist in this guide.
WARNING: Do not save your game while the story compilation error is active. Saving over an existing file during this error will permanently wipe your in-game journals. They cannot be recovered after you overwrite the save. Therefore, close the game immediately without saving. Next, use an earlier autosave as your starting point for troubleshooting.
Also on Axeetech: Sibelius Error 40207

What Is the Story Compilation Error DOS2?
The story compilation error happens during the initial startup phase. Initially, the game runs the Osiris compiler to build a Story file. If any mod contains errors, the compiler fails immediately.
This issue is not a graphics error or hardware problem. It is specifically a mod scripting failure instead. The Osiris compiler detected an unresolvable issue and reported it reliably.
The error produces three different on-screen messages constantly. All variants stem from the exact same class of failure. Therefore, understanding your specific message helps identify the cause quickly.
One confirmed side effect involves extra characters appearing in your party. Consequently, the game spawns placeholder characters from failed mod scripts. This remains a direct symptom of an active compilation error.
Also Read: app_w351_csidevice0down Error Code Fixed
DOS2 Story Compilation Error: All Three Message Variants
| Error Message | When It Appears | Primary Cause |
| “STOP! A Story Compilation Error occurred with your active mods. You may be missing mod dependencies. Mods will not work correctly!” | On loading screen when launching with mods | Missing mod dependency or Script Extender not installed correctly |
| “We were unable to create a working Story. Your add-on setup might be invalid. The game will continue with the story from the main adventure.” | On loading screen or when starting new game | Mod with non-compiling code or outdated mod conflicting with patch |
| “WARNING: The files of mod ‘Divinity: Original Sin 2’ and/or its dependencies are invalid. This can be caused by corrupt files…” | On multiplayer session load | Corrupt game files or mismatched mod versions between players |
What Causes the DOS2 Story Compilation Error?
The story compilation error has six confirmed causes. Identifying your specific cause saves significant troubleshooting time. Therefore, review these causes before attempting any complex fixes.
The most common cause is a missing Script Extender. Alternatively, players install the Script Extender in the wrong folder. Consequently, every dependent mod fails to compile without it.
Less obvious causes include leftover files from uninstalled mods. Additionally, Windows usernames containing special characters break the folder path entirely. Finally, mismatched mod versions between co-op players trigger this error immediately.
DOS2 Story Compilation Error: Confirmed Causes
| Cause | Who It Affects | Error Message Produced | Likelihood |
| Script Extender missing or installed in wrong directory | Anyone using mods requiring SE | STOP! Missing mod dependencies | Very Common |
| Outdated mod conflicting with current game patch | Anyone with workshop mods | We were unable to create working Story | Very Common |
| Leftover .pak files from previously uninstalled mods | Anyone who has ever used mods | We were unable to create working Story | Common |
| Mod code with Osiris scripting error | Anyone using third-party mods | We were unable to create working Story | Common |
| Windows username containing special characters | Players with accented PC usernames | Any variant | Less Common |
| Mismatched mod versions between co-op players | Multiplayer co-op players | Dependencies invalid warning | Common in co-op |
| Gift Bag conflicts | Vanilla players using Gift Bags | We were unable to create working Story | Common on vanilla |
Fix by Scenario: Which Situation Are You In?
The correct fix path depends heavily on your mod setup. Players with mods have completely different causes than vanilla players. Choosing the wrong fix path wastes your time entirely.
You might play with mods and see the error suddenly. If you just subscribed to a new mod, that is the cause. Alternatively, an outdated mod became incompatible with a new patch.
You might play with absolutely no external mods installed. In this case, conflicting Gift Bags usually cause the issue. Furthermore, corrupt game files can trigger the exact same error.
Also Read: USA Staffing has encountered an error
Which Fix Path to Use: DOS2 Story Compilation Error
| Your Situation | Most Likely Cause | Start With |
| Using mods + STOP error on new game | Missing Script Extender or wrong SE install path | Fix 1, then Fix 2 |
| Using mods + error after game update | Outdated mod conflicting with new patch | Fix 3, then Fix 1 |
| Using mods + error on existing save | Leftover files from uninstalled mod | Fix 4, then Fix 3 |
| No mods (vanilla/Gift Bags only) + error | Conflicting Gift Bags or corrupt game files | Fix 5, then Fix 6 |
| Multiplayer + Dependencies Invalid warning | Mismatched mod versions between players | Fix 7 |
| Error on clean install (never used mods) | Corrupted game files or Windows username | Fix 6, then Fix 8 |
Fix 1: Install or Reinstall Norbyte’s Script Extender Correctly
Norbyte’s Script Extender is required by many DOS2 mods. Consequently, these mods fail to compile without the extender installed. This specific failure produces the STOP error on your screen.

The most common mistake involves the DXGI.dll file placement. Players often extract it into the main bin folder incorrectly. Instead, the Script Extender must go in the DefEd subfolder.
Once correctly installed, the Script Extender auto-updates on launch. Therefore, you do not need to manually download new versions. The Script Extender version must always match the game version.
You must verify the Script Extender works after installation. Launch the game and watch the initial loading screen closely. You should see the version number displayed at the top.
- Download the Script Extender from Norbyte’s GitHub releases page.
- Extract the downloaded .zip file to your desktop temporarily.
- Locate your DOS2 installation folder via Steam local files.
- Open the DefEd subfolder carefully.
- Open the bin subfolder inside the DefEd folder.
- Place the DXGI.dll file inside this specific DefEd bin folder.
- Launch DOS2 and watch the loading screen very closely.
- Verify the Script Extender version number appears clearly.
- Relaunch the game and test for the compilation error.
IMAGE 2
CRITICAL PATH: The DXGI.dll file must go in the DefEd bin folder. Do not place it in the main bin folder. Placing it in the main bin folder causes a silent failure.
Fix 2: Find and Remove the Conflicting Mod
You must identify the specific broken mod next. First, disable half of your active mods and test the game. Next, narrow down which half contains the broken code.
Outdated mods cause most errors after a game patch. Consequently, mods overriding vanilla scripts break during the update. Always check the Steam Workshop page for recent author updates.
After identifying the broken mod, you must remove it twice. First, remove it from the in-game mod list entirely. Second, delete its .pak file from your Documents folder directly.
- Open the main menu in DOS2 and select Mods.
- Disable all mods except the base game files.
- Start a new game and check the loading screen.
- If gone, re-enable mods in batches of half.
- Test the game again after each newly enabled batch.
- Identify the exact batch where the error finally returns.
- Enable mods one at a time from that bad batch.
- Unsubscribe from the broken mod in Steam Workshop immediately.
- Manually delete its .pak file from your Documents folder.
- Restart the game and verify the error is completely resolved.
TWO-LOCATION DELETE RULE: Unsubscribing from a mod in Steam is not enough. It does not remove the .pak file from your Documents folder. You must manually delete the file from that specific folder. Leaving orphaned files causes bugs similar to what requires learninghow to fix the PR_END_OF_FILE errorin browsers.
Fix 3: Update Outdated Mods After a Game Patch
Larian releases DOS2 patches and updates occasionally. Consequently, abandoned mods become incompatible with the new game version. The story compilation error then appears on your next launch.
Sometimes, no update exists for a conflicting mod. First, disable the mod and wait for an official update. Alternatively, use Steam’s Beta branch to run an older version.
- Open Steam and navigate to your Workshop subscriptions.
- Sort by last updated and identify old mods quickly.
- Check each suspect mod’s page for patch compatibility notes.
- Click Subscribe on the updated version if it exists.
- Delete the old .pak file from your Documents folder.
- Relaunch DOS2 and check the loading screen version actively.
- Test the game for the story compilation error again.
Fix 4: Clear Orphaned Mod Files from Documents Folder
DOS2 copies a .pak file to Documents upon installation. Uninstalling a mod through Steam does not remove this automatically. Consequently, orphaned .pak files accumulate and cause compilation errors constantly.

Clearing orphaned files requires checking your Documents folder manually. Carefully identify any .pak file that lacks an active mod. Subsequently, delete every unmatched file from the folder entirely.
Always back up your save files before clearing the folder. Managing your saves safely is crucial. It mimics finding Stellar Blade save file locations on PC to prevent data loss.
- Back up your saves to a separate folder initially.
- Navigate to your Documents Larian Studios DOS2 Mods folder.
- Compare every .pak file against your active mod list.
- Delete every .pak file lacking an active mod counterpart.
- Check and clear the Public folder within Documents additionally.
- Restart DOS2 and check if the error is resolved.
IMAGE 3
Fix 5: Fix the Gift Bag Conflict (Vanilla / No Mods)
Players using no external mods still encounter this error. Larian’s built-in Gift Bags trigger the exact same compilation failures. Consequently, some Gift Bags conflict with each other directly.
The Hagglers Gift Bag causes story issues on the current patch. Furthermore, the Inventory Sorter remains unstable on Definitive Edition. Disabling these specific Gift Bags resolves the error for most players.
Disabling a Gift Bag mid-playthrough affects your existing saves. Therefore, start a brand new game after changing Gift Bag settings. Afterwards, you can attempt to continue your existing save file.
- Select Story Mode directly from the main menu.
- Select Gift Bags before creating a new game.
- Review your active selections carefully and methodically.
- Disable Hagglers and Inventory Sorter first.
- Start a new game and check for the error.
- If the error persists, disable all Gift Bags entirely.
- If resolved, re-enable Gift Bags individually to find the culprit.
Fix 6: Perform a True Clean Reinstall
A standard Steam uninstall does not fully clean DOS2. It leaves behind non-vanilla files in the game folder. Consequently, previously installed mod files persist through standard Steam reinstalls.
A true clean reinstall requires manual deletion of folders. First, delete the main game folder from Steam entirely. Next, delete the Larian Studios folder located securely in Documents.
Deleting the Documents folder resets corrupted settings files successfully. Deep cleaning prevents lingering issues like Roblox error codes. Therefore, this process remains the most thorough reset available.
- Back up your PlayerProfiles folder to a safe location.
- Uninstall DOS2 completely through your Steam client menu.
- Navigate to your Steam common folder manually.
- Delete the Divinity Original Sin 2 folder completely.
- Navigate to your system’s Documents folder next.
- Delete the entire Larian Studios folder cleanly.
- Reinstall DOS2 through Steam normally.
- Launch the game once without any mods installed.
- Test for the error before re-adding any modifications.
IMPORTANT DELETION RULE: A Steam uninstall is not a clean reinstall. Steam only removes vanilla files. You must manually delete the entire game folder after uninstalling. This fix mirrors the deep cleaning required for how to fix Ubisoft error Dolphin-028.
Fix 7: Sync Mod Versions in Multiplayer
Every co-op player must run identical mod versions. A minor version mismatch triggers the error instantly for everyone. Consequently, the compilation error blocks all players in the session.
You must verify mod versions manually through the main menu. Compare the specific version numbers with all co-op partners carefully. Finally, update any mismatched mods before loading a shared session.
- Ask each player to open the in-game Mods menu.
- Hover over each active mod to reveal its version number.
- Note down the exact version of every active mod.
- Compare these lists with all co-op players involved.
- Any player with a different version must update immediately.
- Ensure all players subscribe to the newest updates.
- Relaunch DOS2 and test the multiplayer session again.
Fix 8: Rename Windows Username Containing Special Characters
Your Windows username might contain special characters or accents. If so, DOS2 cannot correctly read your file path. Consequently, this produces a compilation error with zero mods installed.
The fix requires creating a new Windows user account safely. This prevents path bugs like the State of Play store glitch error CE-107938-8. Finally, launch DOS2 from the new ASCII-only account safely.
- Open Windows Settings and navigate to Accounts.
- Click on the Family & Other Users tab specifically.
- Add a new local account to your PC securely.
- Use only standard ASCII characters in the new username.
- Log in to this new Windows account carefully.
- Copy your save files to the new Documents folder.
- Launch DOS2 and test for the compilation error.
How to Read the Osiris Error Log
Norbyte’s Script Extender writes detailed compilation logs automatically. Reading these logs shows exactly which mod caused the failure. Additionally, it highlights the exact line of failing code.
These logs are stored in your Documents folder by default. Look specifically inside the OsirisLogs directory for these text files. Furthermore, they are named accurately after the specific game session.
Look for lines containing ERROR or FATAL inside the log. These lines identify the specific mod filename very clearly. Consequently, you can easily target that exact file for removal.
- Close DOS2 completely before starting the process.
- Navigate to your Documents folder and find OsirisLogs.
- Open the most recent log file using Notepad.
- Search for the words ERROR or FATAL directly.
- Read the error line to find the failing mod file.
- Note the exact mod filename from that text line.
- Locate that .pak file in your DOS2 Mods folder.
- Remove that specific mod and retest the game.
LOG LOCATION: The log is found in your Documents under OsirisLogs. This log shows exactly which mod caused the compilation failure. Reading it is much faster than manually disabling mods individually. Look for lines containing ERROR or FATAL specifically.
DOS2 Story Compilation Error Symptoms Reference Table
The story compilation error does not always display a popup. Several in-game symptoms signal an active compilation error silently. Therefore, watching for these symptoms prevents long-term save damage.
The most distinctive symptom involves extra characters in your party. Consequently, players often see four or six unnamed characters appearing. This signals a severe script compilation failure immediately.
Missing journal entries represent the most dangerous symptom possible. If you save during an error, journal data is overwritten permanently. Furthermore, this damage cannot be reversed on that specific save.
Symptoms and What They Mean
| Symptom | What It Means | Is It Reversible? |
| STOP! popup on loading screen | Active compilation error: mods did not compile | Yes: fix the mod issue and relaunch |
| Extra unnamed characters in party | Story file compiled with errors: placeholders spawned | Yes: resolves after fixing compilation error |
| Journals blank or entries missing | Saved while error was active: data overwritten | No: use an earlier autosave |
| Mods appearing enabled but not working | Mods loaded without compiling correctly | Yes: fix compilation error and relaunch |
| Game continues but mod abilities absent | Partial compilation failure: some scripts executed | Yes: fix compilation error |
Frequently Asked Questions
The questions below address common points of confusion completely. These answers originate from confirmed Steam community thread solutions exclusively. Furthermore, they source from Larian Studios forums and Nexus Mods.
Will the story compilation error delete my save files?
No. The error itself does not delete the saves directly. However, saving during an active error overwrites your journals permanently. Always use an autosave from before the error appeared.
Can I get the story compilation error without any mods?
Yes. Vanilla players using Gift Bags can trigger this error. The Hagglers and Inventory Sorter bags cause the most issues. Disabling them resolves the error for most vanilla players.
Where exactly does DXGI.dll go for the Script Extender?
The file must reside in the DefEd bin folder. Do not place it in the main root bin folder. Placing it wrong causes the Extender to fail silently.
Why does the error appear after a game update?
Game updates change vanilla scripts that your mods override. Consequently, a mod referencing an old script creates a conflict. Updating or disabling the outdated mod resolves this completely.
Can I recover journals that were wiped by the error?
No. Saving over a corrupted session permanently wipes journal data. That specific data cannot be recovered from the affected save file. Therefore, you must restore a backup autosave immediately.
Does the story compilation error affect achievements?
No. Achievements track from your account data directly. They do not track from the compiled Story file at all. Therefore, the compilation error only affects mod functionality natively.
Is a freelance tech writer based in the East Continent, is quite fascinated by modern-day gadgets, smartphones, and all the hype and buzz about modern technology on the Internet. Besides this a part-time photographer and love to travel and explore. Follow me on. Twitter, Facebook Or Simply Contact Here. Or Email: info@axeetech.com
