# Additional module path disappears after restart

**URL:** <https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357>\
**Category:** Development\
**Tags:** bug, extensions\
**Created:** [December 3, 2025, 7:12pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357 "2025-12-03T19:12:42Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![fedorov](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/fedorov/32/14_2.png) [@fedorov](https://discourse.slicer.org/u/fedorov)\
**Post date:** [December 3, 2025, 7:12pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/1 "2025-12-03T19:12:42Z")

</div>

I am adding a new module directory via application settings, but after restart, the added directory disappears. There are no errors relevant to this during application startup. I observe this with both 5.10 and nightly. I am on a mac. I tried this with an empty directory, and the behavior is the same, so it is not related to the specific module.

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [December 3, 2025, 7:40pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/2 "2025-12-03T19:40:54Z")

</div>

Additional module paths are checked at application startup and if the folder does not exist then it is removed. Could you have a look at the Slicer-NNN.ini file and see what paths are listed there, how they are defined (with relative path?) and if they can be found on your system? Are the folders on a physical disk or some virtual/network drive?

---

<div class="post-metadata">

**Author:** ![muratmaga](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/muratmaga/32/3622_2.png) [@muratmaga](https://discourse.slicer.org/u/muratmaga)\
**Post date:** [December 3, 2025, 8:22pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/3 "2025-12-03T20:22:09Z")

</div>

It is not very useful but I want to add that I have seen this, and couple other variants, such as drag and dropping a module folder onto the Slicer windows not bringing the “add these python scripts to module paths” option, or extension wizard not recognizing some module folders, sporadically on MacOS. Never managed to consistently replicate though.

---

<div class="post-metadata">

**Author:** ![fedorov](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/fedorov/32/14_2.png) [@fedorov](https://discourse.slicer.org/u/fedorov)\
**Post date:** [December 3, 2025, 9:24pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/4 "2025-12-03T21:24:10Z")

</div>

> [@lassoan](#):
>
> Additional module paths are checked at application startup and if the folder does not exist then it is removed.

The folder definitely exists. I created the folder, and selected that folder from the file picker. I confirm the folder itself remains in place after Slicer restart.

> [@lassoan](#):
>
> Could you have a look at the Slicer-NNN.ini file and see what paths are listed there, how they are defined (with relative path?) and if they can be found on your system?

When I look at the `~/.config/slicer.org/Slicer.ini` file, I do not see the added folder anywhere before or after the restart. Is this the right file to check?

> [@lassoan](#):
>
> Are the folders on a physical disk or some virtual/network drive?

Physical drive, main drive on a mac mini.

I do not see this issue on linux.

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [December 3, 2025, 10:02pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/5 "2025-12-03T22:02:21Z")

</div>

The Slicer-NNN.ini file is the [revision-specific config file](https://slicer.readthedocs.io/en/latest/user_guide/settings.html#user-and-revision-specific-settings) in the application’s install path. You can get the path by typing this into the Slicer Python console:

```python
slicer.app.slicerRevisionUserSettingsFilePath

```

If the path is not added to this .ini file then there may be some macOS permission issues. @pieper have you experienced something like this lately?

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [December 3, 2025, 11:42pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/6 "2025-12-03T23:42:54Z")

</div>

> [@lassoan](#):
>
> @pieper have you experienced something like this lately?

I don’t usually use the settings files for this. I use the `--additional-module-paths` command line argument (this helps isolate different experiments using the same Slicer version).

---

<div class="post-metadata">

**Author:** ![fedorov](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/fedorov/32/14_2.png) [@fedorov](https://discourse.slicer.org/u/fedorov)\
**Post date:** [December 9, 2025, 7:53pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/7 "2025-12-09T19:53:23Z")

</div>

> [@lassoan](#):
>
> If the path is not added to this .ini file then there may be some macOS permission issues.

I checked, and this is the file:

```auto
ls -lat /Applications/Slicer-20251129.app/Contents/bin/../slicer.org/Slicer-34291.ini
-rw-r–r–@ 1 rsna2023 admin 1686 Dec 1 15:37 /Applications/Slicer-20251129.app/Contents/bin/../slicer.org/Slicer-34291.ini

```

To add more detail, on this system I installed Slicer under a different account, and then have been using it under the `rsna2023` user account. I confirmed `rsna2023` user can write to this file, but the file is unchanged before or after the restart if I try to remove a path in the Application module settings.

To me, the unresolved questions are:

1. Why is that file remaining unchanged?
2. The way permissions are set up for that file, since application is shared across users on the system, it will definitely be problematic, since it is readable only by one user. Is this a bug?
3. There does not seem to be any error at any point that would indicate failure to modify that settings file. Is this a bug?

Here’s the full contents of the file.

```auto
[Extensions]
[Extensions]
FrontendServerUrl=https://extensions.slicer.org
InstallPath=Extensions-34291
LastServerAPI=Girder_v1
ManagerEnabled=true
MetadataFromServerUpdateTime=2025-12-01T02:52:59Z
MetadataFromServerUrl=https://slicer-packages.kitware.com
ServerUrl=https://slicer-packages.kitware.com

[LibraryPaths]
1\path=Extensions-34291/QuantitativeReporting/lib/Slicer-5.11
2\path=Extensions-34291/SlicerDevelopmentToolbox/lib/Slicer-5.11
3\path=Extensions-34291/IDCBrowser/lib/Slicer-5.11
4\path=Extensions-34291/DCMQI/lib/Slicer-5.11
5\path=Extensions-34291/DCMQI/lib/Slicer-5.11/cli-modules
6\path=Extensions-34291/PETDICOMExtension/lib/Slicer-5.11
7\path=Extensions-34291/PETDICOMExtension/lib/Slicer-5.11/cli-modules
size=7

[Modules]
AdditionalPaths=Extensions-34291/QuantitativeReporting/lib/Slicer-5.11/qt-scripted-modules, Extensions-34291/SlicerDevelopmentToolbox/lib/Slicer-5.11/qt-scripted-modules, Extensions-34291/DCMQI/lib/Slicer-5.11/cli-modules, Extensions-34291/PETDICOMExtension/lib/Slicer-5.11/cli-modules, Extensions-34291/PETDICOMExtension/lib/Slicer-5.11/qt-scripted-modules
IgnoreModules=@Invalid()

[PYTHONPATH]
1\path=Extensions-34291/QuantitativeReporting/lib/Slicer-5.11/qt-scripted-modules
2\path=Extensions-34291/SlicerDevelopmentToolbox/lib/Slicer-5.11/qt-scripted-modules
3\path=Extensions-34291/IDCBrowser/lib/Slicer-5.11/qt-scripted-modules
4\path=Extensions-34291/PETDICOMExtension/lib/Slicer-5.11/qt-scripted-modules
size=4

[Paths]
1\path=Extensions-34291/DCMQI/lib/Slicer-5.11/cli-modules
2\path=Extensions-34291/PETDICOMExtension/lib/Slicer-5.11/cli-modules
size=2

[QT_PLUGIN_PATH]
size=0

```

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [December 9, 2025, 9:50pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/8 "2025-12-09T21:50:19Z")

</div>

I’m not sure how much this behavior is expected in a multi-user environment, but not giving the user any feedback when the .ini file update is failed is definitely a bug that should be fixed. I’ve created an issue for it:

> <https://github.com/Slicer/Slicer/issues/8896>
>
> When the adding "additional module paths" to the Slicer-NNN.ini file fails (e.g.…, due to file permission issues) then the user should get a meaningful error message about it.
> 
> See more information here: https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/7

@fedorov Could @Sunderlandkyl work on this as part of his IDC activities?

---

<div class="post-metadata">

**Author:** ![fedorov](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/fedorov/32/14_2.png) [@fedorov](https://discourse.slicer.org/u/fedorov)\
**Post date:** [December 9, 2025, 10:03pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/9 "2025-12-09T22:03:34Z")

</div>

> [@lassoan](#):
>
> Could @Sunderlandkyl work on this as part of his IDC activities?

Only if this is a trivial fix. There are IDC tasks outside of Slicer development that I need to get Kyle to start working on, once the already assigned Slicer tasks are completed.

---

<div class="post-metadata">

**Author:** ![lassoan](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/lassoan/32/13_2.png) [@lassoan](https://discourse.slicer.org/u/lassoan)\
**Post date:** [December 9, 2025, 10:08pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/10 "2025-12-09T22:08:01Z")

</div>

OK, makes sense, thank you for the clarification.

---

<div class="post-metadata">

**Author:** ![fedorov](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/fedorov/32/14_2.png) [@fedorov](https://discourse.slicer.org/u/fedorov)\
**Post date:** [December 9, 2025, 10:21pm UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/11 "2025-12-09T22:21:34Z")

</div>

> [@lassoan](#):
>
> I’m not sure how much this behavior is expected in a multi-user environment

Until today, I always installed Slicer into the Applications folder on Mac. I moved the app into one of my user folders, and now everything works as expected.

I think the conclusion is that if there is any chance Slicer can be used in a multi-user setting, it should not be installed into the Applications folder on Mac.

---

<div class="post-metadata">

**Author:** ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)\
**Post date:** [December 10, 2025, 12:02am UTC](https://discourse.slicer.org/t/additional-module-path-disappears-after-restart/45357/12 "2025-12-10T00:02:25Z")

</div>

We could change the dmg file to include a link to the user’s local Applications folder rather than the system one.
