from mastodon import Mastodon mastodon = Mastodon( access_token = 'LwtBGTgMZbUhDjCvd2_2tc4n6KQi5AkIrDnjwEUg9sM', api_base_url = 'https://metu.life/' ) file = open("cal.txt", "r") calendar = file.read() if len(calendar) > 15: mastodon.status_post(calendar)