reticivis-net / mediaforge

A Discord bot for editing and creating videos, images, GIFs, and more!
GNU General Public License v3.0
81 stars 28 forks source link

Command 'caption' raised an exception: Forbidden: 403 Forbidden (error code: 50001): Missing Access #231

Closed chickenbutt1 closed 6 months ago

chickenbutt1 commented 6 months ago

Describe the bug

its just not captioning the video

Traceback

:2024-02-12 02:52:19.088811
COMMAND:/caption {'caption': 'josh when uhhhhh'}
TRACEBACK:
Traceback (most recent call last):
  File "/root/.cache/pypoetry/virtualenvs/mediaforge-HXFskkj--py3.12/lib/python3.12/site-packages/discord/app_commands/commands.py", line 827, in _do_call
    return await self._callback(self.binding, interaction, **params)  # type: ignore
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/mediaforge/src/commands/caption.py", line 115, in captioncommand
    await process(ctx, processing.vips.vipsutils.generic_caption_stack, [["VIDEO", "GIF", "IMAGE"]],
  File "/mediaforge/src/core/process.py", line 151, in process
    raise e
  File "/mediaforge/src/core/process.py", line 62, in process
    urls = await imagesearch(ctx, len(inputs))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/mediaforge/src/utils/scandiscord.py", line 82, in imagesearch
    async for m in ctx.channel.history(limit=50, before=ctx.message):
  File "/root/.cache/pypoetry/virtualenvs/mediaforge-HXFskkj--py3.12/lib/python3.12/site-packages/discord/abc.py", line 1804, in history
    data, state, limit = await strategy(retrieve, state, limit)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/root/.cache/pypoetry/virtualenvs/mediaforge-HXFskkj--py3.12/lib/python3.12/site-packages/discord/abc.py", line 1746, in _before_strategy
    data = await self._state.http.logs_from(channel.id, retrieve, before=before_id)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/root/.cache/pypoetry/virtualenvs/mediaforge-HXFskkj--py3.12/lib/python3.12/site-packages/discord/http.py", line 739, in request
    raise Forbidden(response, data)
discord.errors.Forbidden: 403 Forbidden (error code: 50001): Missing Access

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/root/.cache/pypoetry/virtualenvs/mediaforge-HXFskkj--py3.12/lib/python3.12/site-packages/discord/ext/commands/hybrid.py", line 438, in _invoke_with_namespace
    value = await self._do_call(ctx, ctx.kwargs)  # type: ignore
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/root/.cache/pypoetry/virtualenvs/mediaforge-HXFskkj--py3.12/lib/python3.12/site-packages/discord/app_commands/commands.py", line 846, in _do_call
    raise CommandInvokeError(self, e) from e
discord.app_commands.errors.CommandInvokeError: Command 'caption' raised an exception: Forbidden: 403 Forbidden (error code: 50001): Missing Access

Expected Behavior

i expected it to put fucking caption the video

Steps To Reproduce

i put this video in: https://cdn.discordapp.com/attachments/1128327610942894214/1206432297226735636/rLMalYUBLRag.mp4?ex=65dbfca2&is=65c987a2&hm=80eeaa11c882e61b55fabecc9911164665b9fbc888ee6d91bfe3c2c51f0a765d& i captioned it "josh when uhhhh" and then it says it didnt work

Anything Else

this gif will really help with this https://tenor.com/view/mediaforge-discord-rendering-render-finish-gif-25069680

chickenbutt1 commented 6 months ago

i like how i removed the word "put" that i forgot to delete when i retyped the second half of the message and it just stayed there

reticivis-net commented 6 months ago

Does the bot have message history permissions? It needs those…

chickenbutt1 commented 6 months ago

Does the bot have message history permissions? It needs those…

im pretty sure it does ill go check

chickenbutt1 commented 6 months ago

Does the bot have message history permissions? It needs those…

im pretty sure it does ill go check

it does have message history perms

reticivis-net commented 6 months ago

Does the bot have message history permissions? It needs those…

im pretty sure it does ill go check

it does have message history perms

Check again please in the specific channel because the error is saying that it doesn’t have access to get message history, and I can’t reproduce the issue

chickenbutt1 commented 6 months ago

it worked

chickenbutt1 commented 6 months ago

also thanks for replying fast