I thanked a message in my (Flow) talk page at MediaWiki.org, and I got this error message:
Thank action failed (error code: invalidrecipient). Please try again.
As a user, there is nothing I can do, since the recipient is predefined.
The "Thank" links should not be available for posts that are made by bots. This will match the current setup on history/diff pages. (e.g. and e.g.)
Note, this is controlled by $wgThanksSendToBots .