Packages installed using addon manager not showing up in the code

Open
#276 31 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
42/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
python
Domain
tooling

Research direction

Reproduce the failure in a fresh Windows 11 FreeCAD installation using the Addon Manager, then inspect the AdditionalPythonPackages folder and test imports in the Python console. The work is done when shapely.geometry and docx.Document import successfully after installing the Rocket WB optional packages and restarting FreeCAD.

Written by the indexing model from the issue text.

Description

This can be difficult to reproduce. If a package is installed locally, as in for development, this problem is masked. In order to reproduce, I had to create a fresh virtual machine with no FreeCAD installed. With that in mind, do the following:

  1. Install FreeCAD
  2. Using the Addon Manager, install the Rocket WB.
  3. When prompted, include the optional installs: CfdOF, shapely, and python-docx
  4. Restart

Checking the AdditionalPythonPackages folder, all packages are in there. However trying to load them using the Rocket WB produces module not found errors. This can be shown from the Python console:

Python 3.11.13 | packaged by conda-forge | (main, Jun  4 2025, 14:39:58) [MSC v.1943 64 bit (AMD64)] on win32
Type 'help', 'copyright', 'credits' or 'license' for more information.
>>> # Gui.runCommand('Start_Start',0)
>>> # Gui.runCommand('Std_Workbench',11)
>>> # Gui.runCommand('Std_ViewStatusBar',1)
>>> import shapely
>>> from shapely.geometry import Polygon
Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "C:\Program Files\FreeCAD 1.0\bin\Lib\site-packages\shiboken2\files.dir\shibokensupport\feature.py", line 139, in _import
    return original_import(name, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ModuleNotFoundError: No module named 'shapely.geometry'
>>> from docx import Document
Traceback (most recent call last):
  File "<input>", line 1, in <module>
ImportError: cannot import name 'Document' from 'docx' (unknown location)
>>> 


OS: Windows 11 build 22621
Architecture: x86_64
Version: 1.0.2.39319 (Git) Conda
Build type: Release
Branch: (HEAD detached at 1.0.2)
Hash: 256fc7eff3379911ab5daf88e10182c509aa8052
Python 3.11.13, Qt 5.15.15, Coin 4.0.3, Vtk 9.3.0, OCC 7.8.1
Locale: English/United States (en_US)
Stylesheet/Theme/QtStyle: FreeCAD Light.qss/FreeCAD Light/Fusion
Installed mods: 
  * AddonManager 2025.10.16
  * CfdOF 1.33.1
  * manifest.json
  * Rocket 5.0.4

Dominant language
Python
Stars
24
Forks
36
PR merge metrics
No merged PRs in 30d

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from FreeCAD/AddonManager

All issues in FreeCAD/AddonManager

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.