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

Confusing default values for SMTP (TLS/SSL) #143

Open
2 tasks done
UncleSamSwiss opened this issue Feb 28, 2022 · 1 comment
Open
2 tasks done

Confusing default values for SMTP (TLS/SSL) #143

UncleSamSwiss opened this issue Feb 28, 2022 · 1 comment
Labels
bug Something is broken. good first issue Opportunity for newcoming contributors. help wanted Extra attention is needed.

Comments

@UncleSamSwiss
Copy link

Describe the issue

The default values for SMTP are confusing:

# emailTLS -- Use TLS when sending emails
emailTLS: true
# emailSSL -- Use SSL when sending emails
emailSSL: true

You can always only set one of these to true, otherwise celery complains:

EMAIL_USE_TLS/EMAIL_USE_SSL are mutually exclusive, so only set one of those settings to True.

I already tried

  • I've read and searched the documentation.
  • I've searched for similar issues in this repository.

Steps to reproduce the behavior

  1. Create a helm release without setting either emailTLS or emailSSL to false
  2. You won't be able to send emails with the exception below.

Expected behavior

Since port 587 is used in the default values, I would suggest setting only emailTLS to true.

See also here:
https://docs.djangoproject.com/en/4.0/ref/settings/#std:setting-EMAIL_USE_TLS

Screenshots

No response

Exception traceback

celery-notify stderr | [2022-02-28 15:31:11,160: ERROR/ForkPoolWorker-1] Failure while executing task
celery-notify stderr | Traceback (most recent call last):
celery-notify stderr |   File "/usr/local/lib/python3.10/site-packages/celery/app/trace.py", line 451, in trace_task
celery-notify stderr |     R = retval = fun(*args, **kwargs)
celery-notify stderr |   File "/usr/local/lib/python3.10/site-packages/celery/app/trace.py", line 734, in __protected_call__
celery-notify stderr |     return self.run(*args, **kwargs)
celery-notify stderr |   File "/usr/local/lib/python3.10/site-packages/weblate/accounts/tasks.py", line 138, in send_mails
celery-notify stderr |     connection = get_connection()
celery-notify stderr |   File "/usr/local/lib/python3.10/site-packages/django/core/mail/__init__.py", line 35, in get_connection
celery-notify stderr |     return klass(fail_silently=fail_silently, **kwds)
celery-notify stderr |   File "/usr/local/lib/python3.10/site-packages/django/core/mail/backends/smtp.py", line 31, in __init__
celery-notify stderr |     raise ValueError(
celery-notify stderr | ValueError: EMAIL_USE_TLS/EMAIL_USE_SSL are mutually exclusive, so only set one of those settings to True.

Additional context

No response

@nijel nijel added bug Something is broken. good first issue Opportunity for newcoming contributors. help wanted Extra attention is needed. labels Mar 1, 2022
@github-actions
Copy link

github-actions bot commented Mar 1, 2022

This issue seems to be a good fit for newbie contributors. You are welcome to contribute to Weblate! Don't hesitate to ask any questions you would have while implementing this.

You can learn about how to get started in our contributors documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is broken. good first issue Opportunity for newcoming contributors. help wanted Extra attention is needed.
Projects
None yet
Development

No branches or pull requests

2 participants