Model Loading Error in Rasa 3.6.21 on Windows 10 – [WinError 123]

Hi everyone,

I’m encountering a persistent issue when trying to run a model with Rasa Open Source 3.6.21 on Windows 10. The error message I receive is:

Could not load model due to [WinError 123] The filename, directory name, or volume label syntax is incorrect: ‘\\?\C:\Users\My_USER\AppData\Local\Temp\tmp0t1hswm9\components/train_RulePolicy1’.

:test_tube: What I’ve tried so far:

  • Tested with both Python 3.9 and Python 3.10 environments.

  • Created a fresh model using rasa init with Rasa 3.6.21.

  • Changed the TEMP directory path to a shorter location to avoid long file paths.

  • Extracted the model manually and tried pointing directly to the model directory using rasa run --model.

Despite all these attempts, the error persists.

:light_bulb: Observation:

If I temporarily remove the \\\\?\\ prefix from the extracted temp path, the model loads successfully — but that’s obviously not a proper fix. This suggests a bug in how Rasa handles Windows temp paths when loading models.

Has anyone else experienced this?

Thanks in advance!

1 Like

I am also facing the same issue. Are you able to overcome this?

Where/How are you doing this? Thanks!

in your rasa installed path,for example, D:\devsoft\miniconda3\envs\py39\Lib\site-packages\rasa\engine\storage\local_model_storage.py, about around line 125, content: tar.extractall(f"\\\\?\\{temporary_directory}")

add this lines on tarfile.py:[but that’s obviously not a proper fix]

The issue occurred when using Python 3.9.25, and it was working correctly on Python 3.9.21.

1 Like