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 for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi everyone!
I found this very usefull tutorial on youtube talking about how validate emails with PBI by using a Python script, this i'm getting this error:
Do you guys knows how to solve this?
the script is very simple:
from validate_email import validate_email
dataset['Valid Email'] = dataset['Email'].apply(lambda x:validate_email(x))
Thanks!
Solved! Go to Solution.
Hi Leandro,
Couldn't reproduce your issue. The python script works well on my side. It seems like there's something with your data type, are they text type in your dataset?
Regards,
Jimmy Tao
Hi everyone,
I followed the same tutorial but I get another error when running the script:
I used the same code as the tutorial but there he only has 1 column in his dataset and mine consists of multiple columns with multiple date types.
I tested the code and when I removed all other columns, it worked as expected.
Can someone help me out?
Thanks!
DataSource.Error: ADO.NET: Python script error.
<pi>sys:1: DtypeWarning: Columns (5,7,8,26,27) have mixed types.Specify dtype option on import or set low_memory=False.
TypeError: expected string or bytes-like object
</pi>
Details:
DataSourceKind=Python
DataSourcePath=Python
Message=Python script error.
<pi>sys:1: DtypeWarning: Columns (5,7,8,26,27) have mixed types.Specify dtype option on import or set low_memory=False.
TypeError: expected string or bytes-like object
</pi>
ErrorCode=-2147467259
ExceptionType=Microsoft.PowerBI.Scripting.Python.Exceptions.PythonScriptRuntimeException
HELP...
I trying but PWBI get this error.. any help please
Hi Leandro,
Couldn't reproduce your issue. The python script works well on my side. It seems like there's something with your data type, are they text type in your dataset?
Regards,
Jimmy Tao
Thanks a lot for the atention.
After some time, i realized that the problem was really the type as you said.
Thanks! Best Regards!
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 Power BI update to learn about new features.
User | Count |
---|---|
65 | |
63 | |
52 | |
37 | |
36 |
User | Count |
---|---|
82 | |
67 | |
61 | |
46 | |
45 |