Sorry, no console. But there are other ways to inspect your variables. Not using print()
though. You haven't specified whether you're working with a Python visual
directly on the Report
tab, or the Run Python Script
option under the Transform
tab in the Power Query Editor
. I'd suggest the latter.
Try this:
1: In the report tab, click Click Home > Enter Data > Load
without inserting any data.
2: Click Edit Queries
and select Transform > Run Python Script
3: Insert the following snippet in the dialog box:
import pandas as pd
d = {'col1': [1, 2], 'col2': [3, 4]}
df = pd.DataFrame(data=d)
I've just used some sample data since I don't have your dataset
. The important thing here is that both df in my sample and dataset in your sample are of type pandas.core.frame.DataFrame
.
4: Click OK
and you should get this:

Most variables (we'll get to that later) that you import or create should be made available there. In our case we have d
and df
. Click on table
to the right of df
to see this:

I hope this helps!
End note:
About the 'Most variables...' part. It seems that whether or not your variables are made available will depend on the datatype of said variable. I tried using a version of the snippet in your question and found that access_token = df.iloc[0]
returns a variable of type pandas.core.series.Series
. This will for some reason not be available for direct inspection as is the case for d
and df
that are of type dict
and pandas.core.frame.DataFrame
, respectively. So to make access_token
availale to you, you should try access_token = dataset.iloc[0].to_frame()
.