Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError: __init__() got an unexpected keyword argument 'debug' #21

Open
yuriiz opened this issue Dec 19, 2014 · 3 comments
Open

TypeError: __init__() got an unexpected keyword argument 'debug' #21

yuriiz opened this issue Dec 19, 2014 · 3 comments

Comments

@yuriiz
Copy link

yuriiz commented Dec 19, 2014

Documentation on pypi and github says it should be instantiated like this:

SMTPServer(
    self,
    ('0.0.0.0', 465),
    None,
    require_authentication=True,
    ssl=True,
    certfile='examples/server.crt',
    keyfile='examples/server.key',
    credential_validator=FakeCredentialValidator(),
    debug=True
)

However it is not correct as constructor in recent release does not have debug parameter and it results in:

TypeError: __init__() got an unexpected keyword argument 'debug'

Please fix documentation or implement debugging and debug argument.

@bcoe
Copy link
Owner

bcoe commented Dec 26, 2014

@yuriiz do you mind submitting a documentation update, with the initialization format that worked for you?

@yuriiz
Copy link
Author

yuriiz commented Jan 1, 2015

SMTPServer(
self,
('0.0.0.0', 465),
None,
require_authentication=True,
ssl=True,
certfile='examples/server.crt',
keyfile='examples/server.key',
credential_validator=FakeCredentialValidator()
)

lmas pushed a commit that referenced this issue Jan 25, 2015
@lmas
Copy link
Contributor

lmas commented Jan 25, 2015

Did a search for 'debug' in the code and found an artefact in smtp_channel.py. self.debug is never set inside the SMTPChannel so the two lines I linked to is never run. What to do with that, remove them or keep them and revert my commit?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants