xdevplatform / twitter-python-ads-sdk

A Twitter supported and maintained Ads API SDK for Python.
https://twitterdev.github.io/twitter-python-ads-sdk/
MIT License
189 stars 106 forks source link

AttributeError: 'PromotedTweet' object has no attribute '__name__' #273

Open keame opened 3 years ago

keame commented 3 years ago

File "E:\workspace\twitter_server\app\service\ad_promoted_tweets_service.py", line 32, in create_ad_promoted_tweet promoted_tweet.save() File "C:\Users\keame\Envs\twitter_server\lib\site-packages\twitter_ads\utils.py", line 97, in wrapper method = "{}.{}".format(str(args[0].name), str(decorated.name)) AttributeError: 'PromotedTweet' object has no attribute 'name'

tushdante commented 3 years ago

Hey @keame - can you please describe the issue along with steps to reproduce?

keame commented 3 years ago

@tushdante think you!The reason for this problem is that the save() method is deprecated.

@Deprecated('This method has been deprecated and will no longer be available '
            'in the next major version update. Please use PromotedTweet.attach() '
            'method instead.')
def save(self):
            pass