question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How to get the username of an author?

See original GitHub issue

Hi, again, I am trying to get my bot to say my username when I call a command. I type in user = ctx.message.author bot.say(’’’Hello’’’ + user) and an error comes up saying TypeError: must be str, not User I don’t know how to change that into a string, can you please help

Thanks

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
Devoxincommented, Sep 28, 2017

"Hello " + str(user)

0reactions
Devoxincommented, Sep 28, 2017

You know this is for issues with the library right? If you need help join the Discord API server. (discord.gg/discord-api)

Read more comments on GitHub >

github_iconTop Results From Across the Web

how do you get the author's username?
We have multiple option to get author name provided by WP. 1) ... Via this function you can get current user auther name...
Read more >
Get author login name (or username) from commit - git
You can use the Get a commit API to get information about the user who is associated with a commit as the author...
Read more >
get_the_author_meta() | Function
Retrieves the requested data of the author of the current post. ... The user field to retrieve. Default: ''. $user_id int|false Optional. User...
Read more >
Get original author username of retweet - Twitter API v2
Hi, I am using Twitter academic API to collect tweets from certain usernames. I am interested in from whom this group of people...
Read more >
How i get the User Username - Using Django
What you want to do is reference the username field through the User object at the point in time when you need it....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found