Forum Discussion
Microsoft.PowerBI.Scripting.Python.Exceptions.PythonScriptRuntimeException-Transforming data python
- 6 years ago
I was able to fix this. There is no issue with installation of libraries.
Bug is there in PowerBI. Even after providing the path of Python in settings, it expects environment variable PATH to be set with below paths.
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Library\mingw-w64\bin
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Scripts
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Library\bin
Please get this fixed as this is an unnecessary additional step which took 3 days to debug the issue.
From the source code below, you may lost hard dependency modules, please check if you have installed: numpy, pytz, dateutil.
# flake8: noqa
__docformat__ = "restructuredtext"
# Let users know if they're missing any of our hard dependencies
hard_dependencies = ("numpy", "pytz", "dateutil")
missing_dependencies = []
for dependency in hard_dependencies:
try:
__import__(dependency)
except ImportError as e:
missing_dependencies.append("{0}: {1}".format(dependency, str(e)))
if missing_dependencies:
raise ImportError(
"Unable to import required dependencies:\n" + "\n".join(missing_dependencies)
)
Community Support Team _ Jimmy Tao
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- gunjansa_ms6 years ago
Microsoft Employee
I was able to fix this. There is no issue with installation of libraries.
Bug is there in PowerBI. Even after providing the path of Python in settings, it expects environment variable PATH to be set with below paths.
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Library\mingw-w64\bin
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Scripts
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Library\bin
Please get this fixed as this is an unnecessary additional step which took 3 days to debug the issue.
- HeliosOne6 years agoFrequent Visitor
Could you explain how actually you define PATH variable with paths in your message? I am facing same problem and my skill is not enough to fix this. A little guide would be great.
Thank you!
- gunjansa_ms6 years ago
Microsoft Employee
Go to Properties of your PC.
Go to Change settings
Go to Environment Variables
Go to Path in System Variables. Add Paths.
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Library\mingw-w64\bin
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Scripts
C:\Users\gunjansa\AppData\Local\Continuum\anaconda3\Library\bin
- jamesmkfoo6 years agoRegular Visitor
Thank you Sir gunjansa_ms! I solved it by adding anaconda3\Scripts and anaconda3\Library\bin to PATH variable.
- perezco6 years ago
Advocate III
providing that the variable path needto be add ...it is not enough explanation.
This how: https://www.h3xed.com/windows/how-to-add-to-and-edit-windows-path-variable
looks this HeliosOne link https://community.powerbi.com/t5/Desktop/error-Working-Directory-does-not-exit/td-p/676990
if you add them in the Path .. It start the python to work from Anaconda