Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

401 #1

Open
fxnormaluser opened this issue Jan 28, 2018 · 10 comments
Open

401 #1

fxnormaluser opened this issue Jan 28, 2018 · 10 comments

Comments

@fxnormaluser
Copy link

This would be great, if it worked !

discord.errors.HTTPException: UNAUTHORIZED (status code: 401): 401: Unauthorized

It tells me, I have too many instances of .bot running ?

@E-D-A
Copy link
Owner

E-D-A commented Jan 28, 2018

Hi, you are getting a standard 401 error from the Discord server.
You need to check the setup of your Discord bot user.

@fxnormaluser
Copy link
Author

The rest of the bot works fine.

commands work - just the steem.stream background service crashes on startup.

@E-D-A
Copy link
Owner

E-D-A commented Jan 29, 2018

ok. Did you configure the ChannelID where you want the output?

@fxnormaluser
Copy link
Author

yes.

@E-D-A
Copy link
Owner

E-D-A commented Jan 29, 2018

As you are getting a 401 something seems to be off with your bot permissions. Some more output and/or screenshot would be helpful.
Is your ChannelID set to the same channel where you are using the ?help and ?top10 commands?

@fxnormaluser
Copy link
Author

Is this script working for you ?

@E-D-A
Copy link
Owner

E-D-A commented Jan 30, 2018

Yes, it is working.
I wonder why your server is saying your bot is not authorized, it's like it is not logged in.
Can you please provide some more log outputs, both from steemit.log and the console output?
Also, when do you get this error? I assume when you post !curate on steemit.

@fxnormaluser
Copy link
Author

Sorted. Thanks a lot.

I'm curious, which steem-python you are using ...
... I have to:

from steem.instance import set_shared_steemd_instance
from steem.steemd import Steemd
set_shared_steemd_instance(Steemd(nodes=steemd_nodes))

The 401 was a false error, I suppose.

@E-D-A
Copy link
Owner

E-D-A commented Jan 30, 2018

ok, cool 😄
The code you posted above sets the nodes for the whole python process, so any steemd class object would inherit that. But as we only have one Steem instance this code does the same thing:

my_nodes = ['https://api.steemit.com', 'https://rpc.buildteam.io']
steem = Steem(nodes=my_nodes)

I noticed I had the old Steemit RPC nodes in the code. Will update that. But https://api.steemit.com was the first one so it should only have been a problem in case of an issue with that node.

For steem-python I'm not running a too old version. I think I have the one since my merged PR end of last year.

I'm curious to find out the difference. I will try to install a fresh environment and see if I can replicate.

@fxnormaluser
Copy link
Author

Yeah, that bit is broken in steem-python. ( and has been for a while - problems only popped up recently, when Steemit moved from wss to https )

are you on discord ? felixxx#4941

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants