Error in running base code #110

Closed
opened 2023-12-01 15:52:55 +01:00 by Omkarok · 6 comments

TypeError: validate_email() got an unexpected keyword argument 'email_address'

I tried running example code and I got this message. I have all dependencies install n there is no error in import

Please help me with this...

TypeError: validate_email() got an unexpected keyword argument 'email_address' I tried running example code and I got this message. I have all dependencies install n there is no error in import Please help me with this...
Owner

Hey,

please provide a reproducible test case, I want to see the code you're using.

Hey, please provide a reproducible test case, I want to see the code you're using.
Author

Hey karolyi,
Thanks for looking into this.
Here's code i trying.

from validate_email import validate_email as vem
is_valid = vem(
    email_address='example@example.com',
    check_format=True,
    check_blacklist=True,
    check_dns=True,
    dns_timeout=10,
    check_smtp=True,
    smtp_timeout=10,
    smtp_helo_host='my.host.name',
    smtp_from_address='my@from.addr.ess',
    smtp_skip_tls=False,
    smtp_tls_context=None,
    smtp_debug=False)
Hey karolyi, Thanks for looking into this. Here's code i trying. ``` from validate_email import validate_email as vem is_valid = vem( email_address='example@example.com', check_format=True, check_blacklist=True, check_dns=True, dns_timeout=10, check_smtp=True, smtp_timeout=10, smtp_helo_host='my.host.name', smtp_from_address='my@from.addr.ess', smtp_skip_tls=False, smtp_tls_context=None, smtp_debug=False) ```
Author

Hey,

please provide a reproducible test case, I want to see the code you're using.

from validate_email import validate_email as vem is_valid = vem( email_address='example@example.com', check_format=True, check_blacklist=True, check_dns=True, dns_timeout=10, check_smtp=True, smtp_timeout=10, smtp_helo_host='my.host.name', smtp_from_address='my@from.addr.ess', smtp_skip_tls=False, smtp_tls_context=None, smtp_debug=False)

> Hey, > > please provide a reproducible test case, I want to see the code you're using. ` from validate_email import validate_email as vem is_valid = vem( email_address='example@example.com', check_format=True, check_blacklist=True, check_dns=True, dns_timeout=10, check_smtp=True, smtp_timeout=10, smtp_helo_host='my.host.name', smtp_from_address='my@from.addr.ess', smtp_skip_tls=False, smtp_tls_context=None, smtp_debug=False) `
Owner

Can you please paste the entire traceback? I'm suspecting you don't use the latest version.

Can you please paste the _entire_ traceback? I'm suspecting you don't use the latest version.
Author

Can you please paste the entire traceback? I'm suspecting you don't use the latest version.

Here's entire traceback


TypeError Traceback (most recent call last)
in <cell line: 2>()
1 from validate_email import validate_email as vem
----> 2 is_valid = vem(
3 email_address='example@example.com',
4 check_format=True,
5 check_blacklist=True,

TypeError: validate_email() got an unexpected keyword argument 'email_address'

And this error changes to following if I use complete example function. ie with address_type


NameError Traceback (most recent call last)
in <cell line: 2>()
13 smtp_tls_context=None,
14 smtp_debug=False,
---> 15 address_types=frozenset([IPv4Address, IPv6Address]))

NameError: name 'IPv4Address' is not defined

> Can you please paste the _entire_ traceback? I'm suspecting you don't use the latest version. Here's entire traceback --------------------------------------------------------------------------- TypeError Traceback (most recent call last) <ipython-input-33-e67d40e8a2d8> in <cell line: 2>() 1 from validate_email import validate_email as vem ----> 2 is_valid = vem( 3 email_address='example@example.com', 4 check_format=True, 5 check_blacklist=True, TypeError: validate_email() got an unexpected keyword argument 'email_address' And this error changes to following if I use complete example function. ie with address_type --------------------------------------------------------------------------- NameError Traceback (most recent call last) <ipython-input-34-e961867df046> in <cell line: 2>() 13 smtp_tls_context=None, 14 smtp_debug=False, ---> 15 address_types=frozenset([IPv4Address, IPv6Address])) NameError: name 'IPv4Address' is not defined
Owner

This doesn't look like a traceback. What Python version is this?

This doesn't look like a traceback. What Python version is this?
Sign in to join this conversation.
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: karolyi/py3-validate-email#110
No description provided.