Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us at FabCon Vienna from September 15-18, 2025, for the ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM. Get registered
Currently facing an issue trying to use a custom library within a Fabric workspace.
I am creating the library as a .whl file and using %pip install to install it.
If I run %pip list after installation I can see my library appear in the list of packages.
Processing ./builtin/hwbg_helpers-0.0.1-py3-none-any.whl
Requirement already satisfied: pyarrow in /home/trusted-service-user/cluster-env/trident_env/lib/python3.11/site-packages (from hwbg-helpers==0.0.1) (14.0.2)
Requirement already satisfied: numpy>=1.16.6 in /home/trusted-service-user/cluster-env/trident_env/lib/python3.11/site-packages (from pyarrow->hwbg-helpers==0.0.1) (1.26.4)
Installing collected packages: hwbg-helpers
Successfully installed hwbg-helpers-0.0.1
[notice] A new release of pip is available: 24.0 -> 25.0.1
[notice] To update, run: python -m pip install --upgrade pip
Note: you may need to restart the kernel to use updated packages
However when I use the import command
from hwbg_helpers import detect_environment
I get the following error back:
---------------------------------------------------------------------------
ModuleNotFoundError Traceback (most recent call last)
Cell In[10], line 1
----> 1 from hwbg_helpers import detect_environment
ModuleNotFoundError: No module named 'hwbg_helpers'
I have tried the following so far:
It is almost as though it has the wrong context when running %pip install and the packages installed in that context are not available elsewhere in the notebook.
Solved! Go to Solution.
Hi @faheemgani ,
Thank you for reaching out to us on the Microsoft Fabric Community Forum.
Since you installed the package inline using %pip install, you may need to restart the kernel for it to be recognized. Click on Kernel > Restart Kernel in your notebook UI. Then, try importing the package again.
Check out the link below,it describes a similar scenario and might help you to resolve the issue.
Solved: Custom Library not found - Microsoft Fabric Community
If this post was helpful, please give us Kudos and consider marking Accept as solution to assist other members in finding it more easily.
Hi @faheemgani ,
May I ask if you have resolved this issue? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.
Thank you.
Hi @faheemgani ,
I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions. If my response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.
Thank you.
Hi @faheemgani ,
I hope this information is helpful. Please let me know if you have any further questions or if you'd like to discuss this further. If this answers your question, please Accept it as a solution and give it a 'Kudos' so others can find it easily.
Thank you and Regards,
Menaka.
Hi @faheemgani ,
Thank you for reaching out to us on the Microsoft Fabric Community Forum.
Since you installed the package inline using %pip install, you may need to restart the kernel for it to be recognized. Click on Kernel > Restart Kernel in your notebook UI. Then, try importing the package again.
Check out the link below,it describes a similar scenario and might help you to resolve the issue.
Solved: Custom Library not found - Microsoft Fabric Community
If this post was helpful, please give us Kudos and consider marking Accept as solution to assist other members in finding it more easily.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Fabric update to learn about new features.