Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
Hi Guys,
i have the code like here:
= fnGetPath("BUNDLES_PATH_TEST")
- this is my function with argument refrencing to windows environment.
Function is:
let
GetPath = (envVariable as text) =>
let
Source = Python.Execute("
import os
import pandas as pd
env_value = os.getenv(envVariable)
data = [[env_value]]
df = pd.DataFrame(data, columns=['Path'])
"),
df1 = Source{[Name="df"]}[Value],
Path = df1{0}[Path]
in
Path
in
GetPath
without function is working.
But I am getting formula:firewall issue.
So i need to have a function but seems that power query is not consuming my passed argument as text...
Please help,
Jacek
Solved! Go to Solution.
@jaryszek , Try using
let
GetPath = (envVariable as text) =>
let
Source = Python.Execute("
import os
import pandas as pd
env_value = os.getenv('" & envVariable & "')
data = [[env_value]]
df = pd.DataFrame(data, columns=['Path'])
"),
df1 = Source{[Name="df"]}[Value],
Path = df1[Path]
in
Path
in
GetPath
Proud to be a Super User! |
|
@jaryszek , Try using
let
GetPath = (envVariable as text) =>
let
Source = Python.Execute("
import os
import pandas as pd
env_value = os.getenv('" & envVariable & "')
data = [[env_value]]
df = pd.DataFrame(data, columns=['Path'])
"),
df1 = Source{[Name="df"]}[Value],
Path = df1[Path]
in
Path
in
GetPath
Proud to be a Super User! |
|
It worked! thanks.
Unfortunately still formula:firewall error is there...
Best,
Jacek
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
Check out the February 2026 Power BI update to learn about new features.
| User | Count |
|---|---|
| 12 | |
| 12 | |
| 10 | |
| 6 | |
| 5 |