Jump to content

DONKEVLAR Docker Templates


Recommended Posts

Posted (edited)

Support thread for all my Docker Templates for CA.

 

This thread is reserved for issues with the Unraid Docker templates. For issues with an application itself, please redirect your concern to the app's own support channels.

Edited by DonKevlar
Link to comment
  • 3 weeks later...

When I try to play a book, the bot says "Bot is not ready or author not in voice channel, please try again later." I've made sure to join the voice channel first. Log:

 

INFO       - bot             : Bot is Starting Up! | Startup Time: 2024-07-25 23:34:16.887923-04:00
INFO       - bot             : Starting up bookshelf traveller v.Beta_1.0.9
WARNING    - bot             : Please wait for this process to finish prior to use, you have been warned!
INFO       - bot             : Testing Server Connection
INFO       - bot             : Server URL  http://192.168.1.30:13378
INFO       - bot             : Connection Established!
INFO       - bot             : Current Server Status = 200, Good to go!
INFO       - bot             : Providing Auth Token to Server
INFO       - bot             : Cleaning up, authentication
INFO       - bot             : Logging user in and verifying role.
INFO       - bot             : ABS user logged in as ADMIN with type: admin
INFO       - bot             : Audio module loaded!
INFO       - bot             : MULTI_USER module loaded!
INFO       - bot             : Initializing Sqlite DB
INFO       - bot             : Shard ID 0 | Starting Shard
INFO       - bot             : Shard ID 0 | Shard is attempting to connect to gateway...
INFO       - bot             : Shard ID 0 | Gateway connection established
INFO       - bot             : Overwriting 0 with 17 application commands
INFO       - bot             : Registered initial user Audiobook-bot successfully
ERROR      - bot             : POST::https://discord.com/api/v10/channels/1265978577376120845/messages: 403
ERROR      - bot             : Ignoring exception in Startup(): HTTPException: 403|Forbidden || Cannot send messages to this user
INFO       - bot             : []
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': ''}
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'T'}
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'The Hung'}
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'The Hunge'}
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'The Hunger '}
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'The Hunger Games'}
INFO       - bot             : Command Called: play with event.ctx.args = ['The Hunger Games'] | event.ctx.kwargs = {'book': 'The Hunger Games'}
INFO       - bot             : []
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': ''}

 

Link to comment
Posted (edited)

Hey, by chance are you using a private channel? If the bot doesn't have permission for a private channel the API call fails. And that's what it looks like is happening here. Try adding the bot role to that channel. You don't need to restart the bot. Just make sure that it has access to that channel. Also, what intents did you use when adding the bot? I'm working on finalizing my guide, but that also might be why it's not working. Note that that can be adjusted in the server you added it to under roles. You can modify what the bot has access to. The main scopes are: Bot(join voice, send messages, read messages). 

Edited by DonKevlar
Link to comment
Posted (edited)
23 hours ago, cliffdog510 said:

When I try to play a book, the bot says "Bot is not ready or author not in voice channel, please try again later." I've made sure to join the voice channel first. Log:

 

INFO       - bot             : Bot is Starting Up! | Startup Time: 2024-07-25 23:34:16.887923-04:00
INFO       - bot             : Starting up bookshelf traveller v.Beta_1.0.9
WARNING    - bot             : Please wait for this process to finish prior to use, you have been warned!
INFO       - bot             : Testing Server Connection
INFO       - bot             : Server URL  http://192.168.1.30:13378
INFO       - bot             : Connection Established!
INFO       - bot             : Current Server Status = 200, Good to go!
INFO       - bot             : Providing Auth Token to Server
INFO       - bot             : Cleaning up, authentication
INFO       - bot             : Logging user in and verifying role.
INFO       - bot             : ABS user logged in as ADMIN with type: admin
INFO       - bot             : Audio module loaded!
INFO       - bot             : MULTI_USER module loaded!
INFO       - bot             : Initializing Sqlite DB
INFO       - bot             : Shard ID 0 | Starting Shard
INFO       - bot             : Shard ID 0 | Shard is attempting to connect to gateway...
INFO       - bot             : Shard ID 0 | Gateway connection established
INFO       - bot             : Overwriting 0 with 17 application commands
INFO       - bot             : Registered initial user Audiobook-bot successfully
ERROR      - bot             : POST::https://discord.com/api/v10/channels/1265978577376120845/messages: 403
ERROR      - bot             : Ignoring exception in Startup(): HTTPException: 403|Forbidden || Cannot send messages to this user
INFO       - bot             : []
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': ''}
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'T'}
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'The Hung'}
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'The Hunge'}
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'The Hunger '}
INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'The Hunger Games'}
INFO       - bot             : Command Called: play with event.ctx.args = ['The Hunger Games'] | event.ctx.kwargs = {'book': 'The Hunger Games'}
INFO       - bot             : []
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': ''}

 

 

 

The other issue I spotted is that you are connecting to the library but its not returning an array or libraries. Autocomplete pulls from 2 things: your recent-sessions (Last 10 sessions you used) and when typing your actual library and uses the search api to find the book you are typing in. (Also returns 10 books using substring search (i.e words included in the txt box).

For example a normal log response should look like this:

 


INFO       - bot             : Successfully Reached /libraries with Status 200
INFO       - bot             : Successfully Reached /libraries/5427680c-4e01-4d59-94d4-c73e5039fa9f/search with Status 200
INFO       - bot             : [{'name': 'He Who Fights with Monsters 8', 'value': 'dc2e19d2-c25a-4c1e-b681-84a73db8cacd'}, {'name': 'He Who Fights with Monsters 7', 'value': 'b19d9791-286d-4e83-b931-52174235f62c'}, {'name': 'He Who Fights with Monsters 9', 'value': '36ef8311-f3cb-48cf-a698-a34548792c36'}, {'name': 'He Who Fights with Monsters 10 (Unabridged)', 'value': 'adc7c114-678c-4873-8ed6-7c4767e7574e'}, {'name': 'He Who Fights with Monsters 6 (Unabridged)', 'value': '933ce643-979b-4c47-9fb6-4ed484592ca1'}, {'name': 'He Who Fights with Monsters 5 (Unabridged)', 'value': '5b7f5bf3-2bc6-4ee7-8383-c4fd23683111'}, {'name': 'He Who Fights with Monsters 4: A LitRPG Adventure (He Who Fights with Monsters, Book 4) (Unabridged)', 'value': '4cb3d333-8934-487a-9186-24e46d3dd515'}, {'name': 'He Who Fights with Monsters 3: A LitRPG Adventure (He Who Fights with Monsters, Book 3) (Unabridged)', 'value': '66c4727b-35f9-40a5-a7ff-fd15c7e15b7e'}, {'name': 'He Who Fights with Monsters 2: A LitRPG Adventure (He Who Fights with Monsters, Book 2) (Unabridged)', 'value': '486f68f5-edb5-4cf7-b250-b06d2d0e6664'}, {'name': 'He Who Fights with Monsters: A LitRPG Adventure (Unabridged)', 'value': 'e3b076e9-f40b-407d-a39f-efb9c914ce8f'}]
INFO       - bot             : Autocomplete Called: $play with event.ctx.focussed_option = SlashCommandOption() | event.ctx.kwargs = {'book': 'He who fights with monsters'}

 

My other suggestion, try getting the item id for a book and try using that in the 'book' prompt. You can get that item id by clicking on an item in the web ui for ABS. it looks like 'dc2e19d2-c25a-4c1e-b681-84a73db8cacd' as an example. The server expects the value to be that item id. If its invalid then it just returns None. So it won't play anything.

What type of library are you using, is it audiobooks only or do you have it mixed? Sorry for the questions, the reason why this is in beta is also due to the fact that I'm still working on niche use cases and setups. 

 

Update:

 

Took a look at the bookshelf API code I had made for the library lookup, turns out that some of the conditions in there were too strict and might of been removing options. I updated the scripts to include all libraries. The new version is Beta 1.1.0. Note that you still need to update your bot's intents if you haven't already to what I spoke of previously. Its attempting to send you messages but cant. But the autocomplete returning an empty list should be fixed now.

Edited by DonKevlar
Link to comment

That worked! I didn't realize you have to set permissions of your bot from the "Installation" tab on the Discord Developer Portal. After doing that and updating the docker, the autocomplete works as intended and everything works perfectly! 😁

Thanks, you're a legend! 🙏🙏🙏

  • Like 1
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...