support DOMAIN_GMX_SG

This commit is contained in:
2024-09-17 11:55:44 +02:00
parent ae423b5d2e
commit 842588d99e
12 changed files with 126 additions and 131 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
from src.utils.excel_reader import read_contacts
_contact_list = read_contacts(file_name="/Users/panlei/Desktop/yahoo_aol_valid_23.xlsx")
_contact_list = read_contacts(file_name="/Users/panlei/Desktop/contact_list_2024-04-03.xlsx")
# print(_contact_list)
for _contact in _contact_list:
if _contact.last_name is None or _contact.first_name is None:
+1 -1
View File
@@ -6,7 +6,7 @@ from src.utils.excel_reader import read_contacts
# 检查联系人表的有邮件有没有在数据库中
if __name__ == '__main__':
contacts = read_contacts(str(Path.home()) + "/Desktop/contact_list_2024-06-01.xlsx")
contacts = read_contacts(str(Path.home()) + "/Desktop/30_05_to_test.xlsx")
mail_list = MONGO_STORE_MANAGER.get_destination_emails()
print("mail_list size is " + str(len(mail_list)))
mail_raw_list = []
@@ -26,6 +26,7 @@ def get_contact_list() -> list:
def get_info_from_ip(ip_address) -> Union[None, IPLocationInfo]:
_ip_info = None
try:
print("get ip info from ip address: " + ip_address)
response = requests.get("http://ip-api.com/json/" + ip_address)
response.raise_for_status()
ip_in_dict = json.loads(response.text)
+29
View File
@@ -0,0 +1,29 @@
from src import config
from src.mail.mail_sender import MailSender
store = "Hermès Paris Faubourg"
# store = "Hermès Paris George V"
# store = "Hermès Paris Sèvres"
# dest_email = "928490803@qq.com"
# dest_email = "1757344572@qq.com"
# dest_email = "392417782@qq.com"
# dest_email = "linghuili@hotmail.com"
dest_email = "panleicim@gmail.com"
# dest_email = "fanfan19810617@icloud.com"
# dest_email = "fanchunying323@163.com"
# dest_email = "lytlaure@gmail.com"
# dest_email = "arianezhangsn@yahoo.com"
# dest_email = "tranthu.ht1983@gmail.com"
# dest_email = "124652097@qq.com"
# dest_email = "sunrose75015@gmail.com"
# dest_email = "1340219934@qq.com" #小于
# dest_email = "lytlaure@gmail.com"
# dest_email = "m13805869912@163.com"
# dest_email = "tangliang0411@gmail.com"
contact_name = "LONG luji"
f = open(config.ROOT_DIR + "/templates/confirmed_rdv.html", "r")
email_body = f.read()
print(email_body)
sender = MailSender(dest_email=dest_email, email_body=email_body, store=store, contact_name=contact_name)
print(sender.send().json)