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

"Error 401 on request" error #37

Open
PolliSoft opened this issue Oct 16, 2020 · 8 comments
Open

"Error 401 on request" error #37

PolliSoft opened this issue Oct 16, 2020 · 8 comments
Labels
bug Something isn't working

Comments

@PolliSoft
Copy link

I just built the non-Docker version of OMBI-bot for Telegram. However, when I run it I get the following error and I don't know how to troubleshoot it.

OMBI-Bot version 2.1. (Same error on master branch)
OMBI is v4.0.483.0.
My env file is:

OMBI_HOST=http://localhost:5000
OMBI_KEY=xyzombikeyxyz
OMBI_BOT_TOKEN=xyzbotkeyxyz
OMBI_BOT_NAME=@bot_name

java -jar c:\Utils\ombi-bot-2.1.jar -p c:\Utils\ombi-bot.env

[trace, com.bot4s.telegram.clients.ScalajHttpClient] REQUEST 1fce7bda-2d06-4982-918d-b573ed4cfb1e DeleteWebhook
[error, com.bot4s.telegram.clients.ScalajHttpClient] RESPONSE 1fce7bda-2d06-4982-918d-b573ed4cfb1e java.lang.RuntimeException: Error 401 on request
Exception in thread "main" java.lang.RuntimeException: Error 401 on request
at com.bot4s.telegram.clients.ScalajHttpClient.$anonfun$sendRequest$13(ScalajHttpClient.scala:107)
at scala.util.Success.$anonfun$map$1(Try.scala:251)
at scala.util.Success.map(Try.scala:209)
at scala.concurrent.Future.$anonfun$map$1(Future.scala:288)
at scala.concurrent.impl.Promise.liftedTree1$1(Promise.scala:29)
at scala.concurrent.impl.Promise.$anonfun$transform$1(Promise.scala:29)
at scala.concurrent.impl.CallbackRunnable.run(Promise.scala:60)
at java.util.concurrent.ForkJoinTask$RunnableExecuteAction.exec(Unknown Source)
at java.util.concurrent.ForkJoinTask.doExec(Unknown Source)
at java.util.concurrent.ForkJoinPool$WorkQueue.runTask(Unknown Source)
at java.util.concurrent.ForkJoinPool.runWorker(Unknown Source)
at java.util.concurrent.ForkJoinWorkerThread.run(Unknown Source)
@StackTraceYo
Copy link
Owner

@PolliSoft gonna try and reproduce it tonight

@StackTraceYo StackTraceYo added the bug Something isn't working label Oct 16, 2020
@daurpam
Copy link

daurpam commented Nov 15, 2020

Hello, I've just installed the bot on v4 and seems to load well, @PolliSoft Did you try to remove "@" from your OMBI_BOT_NAME variable, I've seen this error the first time run in docker, and I don't use @ to name bot.
Try it

@PolliSoft
Copy link
Author

Tried it now, same error.

@StackTraceYo
Copy link
Owner

@PolliSoft does that happen on boot? or after you try and run a command?

@PolliSoft
Copy link
Author

On boot.

@StackTraceYo
Copy link
Owner

that usually indicates either a wrong bot token/bot name or your other bot is still running

@PolliSoft
Copy link
Author

PolliSoft commented Nov 17, 2020

I got it to work. I want to call it a rookie mistake...
I had to remove the comments "// " on each line of the .env file. I thought that the double back slashes escaped the explanation.
When I see the pasted .env file I gave you, I feel really ashamed!!!

@StackTraceYo
Copy link
Owner

no thats my fault. i will make a change to it so it ignores those

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants