python7 aiosmtpd pytest 보호되어 있는 글 입니다. 2023. 2. 9. 이것저것 보호되어 있는 글 입니다. 2023. 1. 27. report 생성 보호되어 있는 글 입니다. 2023. 1. 23. python single line to multi line smtp error 500 line too long이 발생함. image를 encoding해서 보낼 때 line이 너무 길어서 발생한 문제로 multi line으로 변환해서 해결함. step = 10 a = "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa" text = [a[i:i+step] for i in range(0, len(a), step)] text = "\n".join(text) print(text) [output] aaaaaaaaaa aaaaaaaaaa aaaaaaaaaa aaaaaaaaaa aaaaaaaaaa aaaaaaaaaa aaaaaaaa for i in range(0, len(a), step)를 통해 i에 .. 2023. 1. 18. aiosmtpd 보호되어 있는 글 입니다. 2022. 12. 29. python fake data (mimesis) https://mimesis.name/en/master/getting_started.html#basic-usage Getting Started — Mimesis 6.0.0 documentation Data Providers Mimesis support over twenty different data providers available, which can produce data related to food, people, computer hardware, transportation, addresses, and more. See API for more info. Warning Data providers are heavy objects since eac mimesis.name mimesis 6.0.0 inst.. 2022. 9. 10. python fake data with multiprocess (Faker) from concurrent.futures import ProcessPoolExecutor import os import threading import time from faker import Faker import csv fake = Faker() csv_save_dir = './save_csv/' worker_count = 5 per_row = 20000 file_name = "test.txt" file_num = list(range(worker_count)) if not os.path.exists(csv_save_dir): os.makedirs(csv_save_dir) def write_fake_data(file_num): csv_file_save_path = os.path.join(csv_save.. 2022. 9. 9. 이전 1 다음 반응형