#1538·tweepy

Calculate tweet weighted length

Author: egpbosCreated Feb 25, 2021Updated Aug 29, 2026
LabelsRFCFeature Request

If Tweepy could itself calculate the weighted length of a tweet, we could more easily prevent update_status errors of the kind TweepError: [{'code': 186, 'message': 'Tweet needs to be a bit shorter.'}] and actually prevent the failing API call at all by checking for maximum weighted length before calling the API.

Is there already an easy way to do this? If not, do you think it's worthwhile to add it? If so, I may try to do a PR on it.