#Allgemeine Hilfe

1 messages · Page 20 of 1

indigo sapphire
#

startet es einfach nicht am server?

silk gulch
#

exakt.

#

Über PyCharm startet er wie gesagt.

#

Aber über Server (Debian 11) nicht.

indigo sapphire
#

dann ist discord dort nicht installiert?

#

wenn ja richtig so sonst frag jemand der server selber hostet mit rastberry

silk gulch
indigo sapphire
#

wo ist dein ordner?

#

für den bot

silk gulch
#

/home/infinitely

indigo sapphire
#

naja ich hab es auch auf einem server drauf von party man und es gab kein problem

silk gulch
#

Jetzt habe ich folgendes:

Traceback (most recent call last):
  File "/home/infinitely/main.py", line 6, in <module>
    intents = discord.Intents.default()
AttributeError: module 'discord' has no attribute 'Intents'```
indigo sapphire
#

lol?

#

mit intents musst du jemand anderes fragen

silk gulch
#

Anscheinend war es nicht python3.8, sondern python3.9

#

Jetzt geht's...

[LISTENER] OnGuildJoin.py geladen!
[LISTENER] OnReady.py geladen!
[TASK] BotStatus.py geladen!```
indigo sapphire
storm seal
#

Wie kann ich ein modal senden ob wohl ich noch einmal response habepy await interaction.response.send_modal(GrundlModal(title="Erstelle ein Embed")

indigo sapphire
#

warum nicht einfach send anstatt response

mental hamlet
#

Mit timos Tutorial

burnt prairieBOT
#

Mein Discord Server
https://discord.gg/zfvbjTEzv6

▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
Mein Hosting* ► https://tidd.ly/3gJufg6
Code auf Github ► https://github.com/tibue99/tutorial-bot

PYCORD
Docs ► https://docs.pycord.dev/
Guide ► https://guide.pycord.dev/introduction/
Discord Server ► https://discord.gg/pycord

Discord Developer Portal ► https://discord...

▶ Play video
mental hamlet
limpid wolf
#

Wie kann man mehrere Views bei einer Nachricht mit senden?

#

Nevermind ich habs anders gemacht

indigo sapphire
solid ingot
#

mehrere views gehen nicht, nur mehrere elemente innerhalb eines views

indigo sapphire
#

ahh

#

ich hab nur mehrere button oder select menü über 1 views

limpid wolf
indigo sapphire
#

naja so nebenbei hab ich da ein kleine bug durch nicht url senden, problem ich kann kein file entfernen

limpid wolf
#
embed.remove_image()```
limpid wolf
normal sundial
#

Tag 3 mit neuem versuch hat jemand eine idee?

indigo sapphire
#

seh ich nicht das es funktionieren könnte

solid ingot
#

und noch ein tipp: wenn du möchtest, das deine nachricht nicht im chat untergeht, kannst du auch einen neuen post für dein problem erstellen

normal sundial
normal sundial
mystic sentinel
#

was muss ich nocmal installieren für dotenv?

solid ingot
#

python-dotenv

cloud cedar
#

Wie mach ich in sharex zwei effekte auf ein Bild? (Mac OS und gradient)

mental hamlet
#

macos

#

sure

#

heißt das

indigo sapphire
#

Kann man in eine classe variable vererben?

cloud cedar
mental hamlet
#

tutorial

#

auf yt

storm seal
#

Wie kann man das so machen das man nur von bis eingeben kann

urban glen
#

Hast du doch

#

Da steht doch „Gib eine Zahl zwischen 1 und 42 ein.“

#

Von -> 1
Bis -> 42

storm seal
#

das ist Timo sein bot

urban glen
#

Ah okay

#

Nutzt du pycord?

storm seal
#

ja

urban glen
#

min_value=1
max_value=42

storm seal
#

min_length und max_length wollte dich texten

burnt prairieBOT
#
Vielen Dank 😳

Danke UwU, aber ich habe bereits unendlich viele Kekse keks

urban glen
#

Dann so

#

Idk

snow hatch
#

moin dumme frage, aber in pycharm macht er es so wenn ich irgendwo in meinem code hindrücke dann anstatt das ich das normal zwischen zwei zeichen bearbeiten kann löscht er einfach denn vordere nbuchstaben sobald ich was schreibe

#

Wo kann man das ausschalten oder liegt es nicht an pjcharm?

solid ingot
#

drück mal auf einfügen

#

rechts neben enter

snow hatch
#

ohpeepopray

snow hatch
#

ist sie importiert?

#

import random muss oben stehen

urban glen
#

Ob du random importiert hast

#

Du hast es falsch Formuliert

#

Woher sollen wir wissen was du genau meinst

#

Ich habs so verstanden, dass du ein Problem mit der random library hast

#

Kann sein, dass er die Nachricht nicht schickt, weil der Member das deaktiviert hat

#

Gibt sowas, dass man auch erst nh Fa schicken muss um zu schreiben

#

Und ohne Code und Error können wir dir erst recht nicht helfen

#

Komisch daran kann nichts sein

#

Im programmieren is alles Logisch

#

Sehr cleaner Codepepecry

storm seal
#

chill doch

urban glen
#

Lak lass mich zu Ende scheißen

#

Dann helf ich dir

#

So, jetzt werd ich dir nicht helfen

#

Junge

#

Hast du jetzt 5 Minuten gewartet, um mich nochmal zu Pingen?

#

Schon wieder ein Ping

#

Junge reicht jetzt

#

Wenn du dich für Lustig hältst, dann geh in die 90° Ecke in deinem Zimmer und lach da alleine drüber

snow hatch
#

Hey, programmiere gerade ein stadt land fluss und will das man themen hinzufügen kann, dafür will ich gerne das die eingabe das users in eine neue stelle in einer liste getan wird
Wie kann ich also eine neue Stelle erstellen wo dann der input reingeht

snow hatch
#

Danke für die Hilfe schonmal

solid ingot
#

neue elemente kannst du mit list_name.append() hinzufügen

snow hatch
#

ah ok danke

vivid sky
#

Command names and options must be lowercase.

erklärt mir bitte diesen error.

solid ingot
vivid sky
#

achso

#

stimmt

#

vergessen

#

danke timo

tawdry leaf
#

das sind basics 😮

wise stone
#

jo

#

ne Frage wie kann ich variablen erstellen für meine Welcome system z.b. guild_name und es soll halt den Server Name zeigen durch DB abfragen aber wie geht es weil Baum

storm seal
#

was muss ich den hier machen möchte self.bot an ein modal über geben und habe es auch gemacht was muss aber da open rein?

solid ingot
#

self.bot

storm seal
#
modal = TutorialModal(title="Erstelle ein Embed", (self.bot))```
oder wo muss das rein
solid ingot
#

ne, mit Komma trennen

storm seal
solid ingot
#

apo

storm seal
#

och timo

solid ingot
#

erst bot, dann title

urban glen
urban glen
#

z.B. dann er gibt an $membername, dann wird das mit {member.name} geswitcht

indigo sapphire
#

Hey Leute kann mir jemand beim paginator helfen

#

Ich hab das Problem ich kann nicht auf dieselbe paginator classe in einem paginator sollte diese variable current_page in einem custom_view Variable rein

#

Ich brauche nur den Page index: 1/3 die Zahl 1 yk?

limpid wolf
#

Wie genau sendet man bei interaction die nachricht in einem bestimmten kanal?

solid ingot
#

mit send()

limpid wolf
limpid wolf
#

ja auch mit await channel.send geht es nicht

urban glen
#
em = self.embed.copy()
channelid = select.values[0].id
channel = interaction.client.get_channel(channelid)

await channel.send(embed=em)
await interaction.response.send_message("test")
urban glen
#
Ignoring exception in command owner regeln kurz:
Traceback (most recent call last):
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 124, in wrapped
    ret = await coro(arg)
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 976, in _invoke
    await self.callback(self.cog, ctx, **kwargs)
  File "D:\Louis\NightLand\Main\Commands\owner.py", line 31, in _kurz
    await logchannel.send(f"{PFEIL} Das **Kurzgefasste - Regelwerk** Embed wurde in {channel.mention} geschickt!\nVon: {ctx.user.mention}\nButton Rolle: ")
TypeError: can't send non-None value to a just-started coroutine

Kann jemand helfen? Code ist im Fehler

urban glen
#

Da sind links drin ._.

urban glen
#

Schick als Screenshot

#

Als ob es irgendwen juckt

#

Oder entfern die halt

#
    @regeln.command(name=f"kurz", description=f"› Schicke die kurzen Regeln in ein Kanal")
    @commands.has_role(1075904631282077836)
    @discord.guild_only()
    async def _kurz(self, ctx, channel: Option(discord.TextChannel, f'{PFEIL} Der Channel wo die Regeln reingeschickt werden sollen', required=True)):
        print(f"{PFEIL} Embed wird erstellt.")
        banner = discord.Embed(color=0x9B72DD)
        banner.set_image(url=f"ein link")
        embed = discord.Embed(
            title=f"**NightLand  -  Regelwerk**",
            description=f"meine regeln",
            color=0x9B72DD
        )
        embed.set_image(url="zwei link")
        print(f"{PFEIL} Das Embed wurde erfolgreich erstellt")
        await ctx.respond(f"{PFEIL} Du hast das **Kurzgefasste - Regelwerk** Embed in {channel.mention} geschickt!\nUnd wenn jemand auf den **Bestätigen Button** klickt kriegt er die ??? Rolle", ephemeral=True, delete_after=8)
        await channel.send(embeds=[banner, embed])
        logchannel = self.client.fetch_channel(1077949003683078254)
        await logchannel.send(f"{PFEIL} Das **Kurzgefasste - Regelwerk** Embed wurde in {channel.mention} geschickt!\nVon: {ctx.user.mention}\nButton Rolle: ")
solid ingot
urban glen
#

YAY

#

:D

#

Krieg ich dafür eine Custom Rolle kappa_gif

urban glen
#

PFEIL = "›"

#

:)

#

Also das mit Channel.send etc geht nur der schickt das nd in den logchannel

burnt prairieBOT
#
Ghost Ping

@severe citrus hat @solid ingot gepingt.

Nachricht
@solid ingot haste den schonmal gesehen? ```py
Traceback (most recent call last):
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\bot.py", line 1114, in invoke_application_command
await ctx.command.invoke(ctx)
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 375, in invoke
await injected(ctx)
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 124, in wrapped
ret = await coro(arg)
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 1310, in _invoke
await command.invoke(ctx)
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 375, in invoke
await injected(ctx)
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 124, in wrapped
ret = await coro(arg)
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 1310, in _invoke
await command.invoke(ctx)
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 375, in invoke
await injected(ctx)
File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 132, in wrapped
raise ApplicationCommandInvokeError(exc) from exc
discord.errors.ApplicationCommandInvokeError: Application Command raised an exception: TypeError: can't send non-None value to a just-started coroutine
C:\Program Files\WindowsApps\PythonSoftwareFoundation.Python.3.10_3.10.2800.0_x64__qbz5n2kfra8p0\lib\asyncio\events.py:80: RuntimeWarning: coroutine 'Client.fetch_channel' was never awaited
self._context.run(self._callback, *self._args)
RuntimeWarning: Enable tracemalloc to get the object allocation traceback

urban glen
#

NE DIGGA

#

DAS IST PEINLICh

#

HAHHAHA

#

hab ein await vergessen

mental hamlet
#

ALARM

urban glen
urban glen
#

xd

vivid sky
#

Wie mache ich das eine sache 4 mal ausgeführt werden soll aber ohne while True:

quiet socket
#

wie kann ich die main.py als standart setzen?

#

pycharm

solid ingot
#

wenn du die main.py einmal ausführst, sollte das automatisch als standard festgelegt werden

quiet socket
#

funkt net

quiet socket
#

der droppt immer errors

solid ingot
urban glen
#

Das liegt an deinem Code

#

Der error

urban glen
quiet socket
#
bot = discord.Bot(
    intents=intents,
    debug_guilds=[1008126803812036720]
)```
urban glen
#

Hast du ihn mehrmals definiert?

#

Schick mal deinen ganzen Code

quiet socket
quiet socket
urban glen
quiet socket
urban glen
#

Bro

#

du kannst deinen command nicht als "bot" definieren

#

Mach so:

@info.command(name="bot")
async def _bot(...):
quiet socket
#

danke

visual swallow
#

Ich bräuchte kurz Hilfe also mein Freund

#

Hier der Fehlercode

#

pip : Die Benennung "pip" wurde nicht als Name eines Cmdlet, einer Funktion, einer Skriptdatei oder eines ausführbaren Programms erkannt. Überprüfen Sie die Schreibweise des Namens, oder ob der Pfad korrekt ist (sofern enthalten), und
wiederholen Sie den Vorgang.
In Zeile:1 Zeichen:1

  • pip install py-cord
  •   + CategoryInfo          : ObjectNotFound: (pip:String) [], CommandNotFoundException
      + FullyQualifiedErrorId : CommandNotFoundException
visual swallow
wise stone
#

Python

visual swallow
#

Achso

#

Sry /:

#

Falsche Version?

#

Er hat ja die 11.0

storm seal
#

weiß einer wie man ein python file in hintergrund laufen lassen kann?

#

ohne ide

storm seal
#

ich möchte ein bot starten wenn mein pc an geht und so das das file mininiert läuft

wise stone
#

geht nicht

#

du musst es immer mauell aktiviere

visual swallow
#

Ich hätte da eine Idde

#

Nimm doch ein Bot Hoster

storm seal
#

tiiiimo wie hast du das avatar Bild verlinken können?

solid ingot
#

[Avatar](link)

storm seal
urban glen
mental hamlet
tawdry leaf
urban glen
tawdry leaf
#

sag ich doch fast

urban glen
#

fast

#

xD

storm seal
#

oder wie soll das gehen xD

mental hamlet
#

variable

#

xD

urban glen
tawdry leaf
#

jo

tawdry leaf
urban glen
#

Is nur ein bsp

#

Ah ich weiß warum, es liegt daran:

#

:D

#

Ich hoffe ich konnte dir bei deinem Code helfen

storm seal
#

wie kann man an besten den msg_count auswahlen. Habe es auch in /rank aber wenn ich es so nach mache wie dort geht es zwar aber nur wenn ich die xp drine lass bekomme aber ein error

urban glen
#

Versuch doch erstmal Breakpoints zu setzten

#

Oder prints zwischen zu machen

#

Dann weißt du so grob, wo der fehler is

vivid sky
urban glen
#

okö

urban glen
#

Kannst auch machen: ```py
for affenarsch in range(4):

urban glen
#

ok

storm seal
#

weiß einer warum respond gelb ist

dense magnet
dense magnet
storm seal
urban glen
dense magnet
# storm seal

So und das kannst du jetzt mal in Übersetzer klatschen

urban glen
storm seal
#

für chat export

urban glen
#

Musst glaube ApplicationContext oder so machen

storm seal
urban glen
#

So ungefähr

#

Wenn ich mich nd irre

storm seal
#

alles gut

urban glen
#

@solid ingot Hast du den fehler schon gesehen?

discord.errors.ApplicationCommandInvokeError: Application Command raised an exception: TypeError: can't multiply sequence by non-int of type 'InputText'

burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @severe citrus, du bist jetzt Level 4 🎉

Du hast insgesamt 71 Nachrichten geschrieben.

urban glen
#
  • Code
#
Ignoring exception in command owner embed:
Traceback (most recent call last):
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 124, in wrapped
    ret = await coro(arg)
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 976, in _invoke
    await self.callback(self.cog, ctx, **kwargs)
  File "d:\Louis\NightLand\Main\Commands\owner.py", line 24, in embed
    modal = embedModal(title="Erstelle ein Embed")
  File "d:\Louis\NightLand\Main\Views\embuilder.py", line 31, in __init__
    discord.ui.InputText(
TypeError: can't multiply sequence by non-int of type 'InputText'

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

Traceback (most recent call last):
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\bot.py", line 1114, in invoke_application_command
    await ctx.command.invoke(ctx)
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 375, in invoke
    await injected(ctx)
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 124, in wrapped
    ret = await coro(arg)
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 1310, in _invoke
    await command.invoke(ctx)
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 375, in invoke
    await injected(ctx)
  File "C:\Users\gehtd\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\commands\core.py", line 132, in wrapped
    raise ApplicationCommandInvokeError(exc) from exc
discord.errors.ApplicationCommandInvokeError: Application Command raised an exception: TypeError: can't multiply sequence by non-int of type 'InputText'
#
import discord
from Utils.config import *

class embedModal(discord.ui.Modal):
    def __init__(self, *args, **kwargs):
        super().__init__(
            discord.ui.InputText(
                label="Channel ID", # 0
                placeholder=f"ID",
                style=discord.InputTextStyle.short,
                required=True
            ),
            discord.ui.InputText(
                label="Titel", # 1
                placeholder="Warungsarbeiten",
                style=discord.InputTextStyle.long,
                required=True
            ),
            discord.ui.InputText(
                label="Description", # 2
                placeholder="Wir sind ab heute in den Wartungsarbeiten",
                style=discord.InputTextStyle.long,
                required=True
            ),
            discord.ui.InputText(
                label="Field 1 Name", # 3
                placeholder="Was kommt neu?",
                style=discord.InputTextStyle.long,
                required=None
            ),
            discord.ui.InputText(
                label="Field 1 Description", # 4
                placeholder="Add a 2nd Field",
                style=discord.InputTextStyle.long,
                required=None
            )
            *args,
             **kwargs
        )

    async def callback(self, interaction):
        client = interaction.client
        channel = client.get_channel(self.children[0].value)
        #if self.children[9].value is not None:
            #banner = discord.Embed(color=0x9B72DD)
            #banner.set_image(url=self.children[9].value)  
        embed = discord.Embed(
            title=f"{self.children[1].value}",
            description=f'{self.children[2].value}',
            color=0x4eb1a9
        )
        if self.children[3].value and self.children[4].value is not None:
            embed.add_field(name=self.children[3].value, value=self.children[4].value, inline=False)
        #elif self.children[5].value and self.children[6].value is not None:
         #   embed.add_field(name=self.children[5].value, value=self.children[6].value, inline=False)
        #elif self.children[7].value and self.children[8].value is not None:
         #   embed.add_field(name=self.children[7].value, value=self.children[8].value, inline=False)


        try:
            #if self.children[9].value is not None:
            #    await channel.send(embed=banner)
            await channel.send(embed=embed)
            await interaction.response.send_message(f'{PFEIL} Das Embed wurde erfolgreich zu __**<#{self.children[0].value}>**__ gesendet.', ephemeral=True)
        except:
            await interaction.response.send_message(f'{PFEIL} Fehler **uwu**', ephemeral=True)

die zeilen mit # ignorieren.

#

Schick mal als screenshot

#

Bin am handy

thick haven
#

Kann mir jmd helfen wenn ich versuche, nach einem modal ein neues modal zu öffnen bekomme ich nen error

Traceback (most recent call last):
  File "C:\Users\jurek\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\ui\modal.py", line 341, in dispatch
    await value.callback(interaction)
  File "c:\Users\jurek\Documents\Development\Python\DC Bots\Xenority-Main\cogs\youtube-pytube.py", line 170, in callback
    await interaction.response.send_modal(modal)
  File "C:\Users\jurek\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\interactions.py", line 1056, in send_modal
    await self._locked_response(
  File "C:\Users\jurek\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\interactions.py", line 1090, in _locked_response
    await coro
  File "C:\Users\jurek\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.10_qbz5n2kfra8p0\LocalCache\local-packages\Python310\site-packages\discord\webhook\async_.py", line 221, in request
    raise HTTPException(response, data)
discord.errors.HTTPException: 400 Bad Request (error code: 50035): Invalid Form Body
In type: Value must be one of {4, 5, 6, 7, 10}.```

Code
```py
class input_msg(discord.ui.Modal):
    def __init__(self, bot: discord.Bot, channel, *args, **kwargs) -> None:
        self.bot = bot
        self.channel = channel

        super().__init__(*args, **kwargs)

        self.add_item(discord.ui.InputText(
            required=True,
            max_length=50,
            label="Field Value",
            placeholder="Field Value Here...",
            style=discord.InputTextStyle.long
            ))



    async def callback(self, interaction: discord.Interaction):
        async with connect() as (conn, cur):
            pattern = r"{([^}]*)}"
            text = self.children[0].value
            results = re.findall(pattern, text)
            erlaubt = ['user', 'url']
            for r in results:
                if r not in erlaubt:
                    return await interaction.response.send_message("Nicht Erlaubt")
            if not r"{user}" in self.children[0].value and not r"{url}" in self.children[0].value:
                return await interaction.response.send_message("Variablen vergessen")
            if not len(self.children[0].value) > 501:
                modal = input_name(self.bot, self.channel, text, title="Wie lautet dein Youtube Name?")
                await interaction.response.send_modal(modal)
            else: 
vivid sky
urban glen
vivid sky
urban glen
#

Aber als screenshot

vivid sky
#

amk der code ist aber gold wert ich schicke es per dm ok?

urban glen
urban glen
#

was denn

#

Ich wette so krass is dein code nd xD

vivid sky
urban glen
#

Kannst aber per dm schicken

#

Aber als screenshot

#

schick mal ganzen cog per dm

vivid sky
# urban glen Ja xD

also keine Ahnung ob du mit epic games Research gearbeitet hast aber ich schon

#

xd

burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @trail locust, du bist jetzt Level 22 🎉

Du hast insgesamt 1,924 Nachrichten geschrieben.

urban glen
#

yo

urban glen
#

Aber als screenshot

#

Wait

#

Junge

#

Diese drecks message requests xD

urban glen
vivid sky
urban glen
#

ich mein mich pingen

#

Regeln sind regeln

urban glen
#

weiß jemand woran es liegt?

solid ingot
#

sieht so aus als wäre pycord falsch installiert worden

urban glen
#

mhm

#

was kann ich dagegen machen?

solid ingot
#

pycord richtig installieren

urban glen
#

py-cord oder pycord?

solid ingot
#

py-cord

urban glen
#

oke hab ich

#

es wird halt auf ein Panel installiert

#

liegt es vielleicht an pycord selbst?

burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @outer fox, du bist jetzt Level 3 🎉

Du hast insgesamt 24 Nachrichten geschrieben.

solid ingot
#

nein ich denke nicht

urban glen
#

das Problem kommt

tawdry leaf
urban glen
#

Mein wait_for event antwortet nicht :(
Code:

@slash_command(name=f"afk", description=f"Stelle dein Status auf AFK")
    async def _afk(self, ctx, grund: Option(str, f'{PFEIL} Warum gehst du afk?', required=False, default=f"Kein Grund angegeben")):
        
        def check(message):
            return message.author == ctx.author
        
        mainlog = await self.client.fetch_channel(1077949003683078254)
        firstanswer = discord.Embed(
            title=f"AFK",
            description=f"Du bist nun wegen ``{grund}`` AFK!",
            color=0x9B72DD
        )
        embed = discord.Embed(
            title=f"AFK",
            description=f"{ctx.author.mention} ist nun wegen ``{grund}`` AFK!",
            color=0x9B72DD
        )
        await mainlog.send(embed=embed)
        await ctx.respond(embed=firstanswer)

        try:
            warten = await self.bot.wait_for("message", check=check)
        except:
            return
        secondanswer = discord.Embed(
            title=f"Oh Hey!",
            description=f"Du bist nun nichtmehr AFK wegen ``{grund}``.",
            color=0x9B72DD
        )
        embed2 = discord.Embed(
            title=f"AFK",
            description=f"{ctx.author.mention} ist nun nichtmehr AFK wegen ``{grund}``!\n Letzte Nachricht {warten.content}",
            color=0x9B72DD
        )
        await mainlog.send(embed=embed2)
        await warten.reply(embed=secondanswer) 
#

Dannach sollte der Bot eigentlich schreiben Du bist nun nichtmehr AFK wegen DER GRUND

#

in einem Embed

solid ingot
#

da wird die methode wohl abgebrochen

#

message content intent hast du ja oder?

urban glen
#

Was soll ich denn da schreiben? AC_lol

urban glen
solid ingot
#

nichts anderes habe ich von dir erwartet du ehrenvoller freiwilliger helfer

urban glen
solid ingot
urban glen
#

hehe

solid ingot
urban glen
#

Aba ich hab ja kein Cooldown drin? sus

solid ingot
#

dann entferne das try except

urban glen
#

timeout=None?

#

AHHHH

#

bruh

#

makes sense

#

im gonna try

#

OMG Es geht immernoch nicht AC_WACOMGWAC

#

Ich weiß warum

#

my bad

#

my bad

#

Ich hab nd Bot sondern client und du hast Bot und deswegen lol

#

Es geht aber hast du eine Idee, wie ich das mache wenn jemand gepingt wird während einem wait for event das der Bot auf die Nachricht antwortet?

solid ingot
#

hmm

#

also mit on_message wäre das deutlich einfacher

#

dann musst du aber irgendwo speichern wer afk ist

urban glen
#

och nö

solid ingot
#

zb in einer liste

#

muss keine DB sein

urban glen
#

das geht?

#

smash

#

Kannst du mir ein beispiel geben?

#

auf süß

solid ingot
urban glen
#

ne

#

Dann ist man selber schuld COPELOL

solid ingot
#

und beim wait for event ist das eh auch so, deswegen ist die liste auf jeden fall besser

solid ingot
urban glen
#

bruh

#

das bringt mir nd viel shy_duck

#

ja damit hab ich nie so richtig mit gearbeitet shy_duck

solid ingot
#

dann wird es zeit, das sind grundlagen

urban glen
#

kannst mir ja ein Private Python kurs geben cap

solid ingot
#

zu listen gibt es viele tutorials

urban glen
#

bitte?

solid ingot
#

danke?

urban glen
#

warum hab ich bitte geschrieben? NC_Kek_Laugh

#

achsoooo

#

bitte im sinne von bitte ein beispiel code :D

solid ingot
#
self.afk = []
urban glen
#

wöw

solid ingot
urban glen
#

gängsta

#

und wie lass ich das reinschreiben etc

#

man timo

solid ingot
urban glen
#

Das hat mir schon mehrgebracht Danke :D

burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @severe citrus, du bist jetzt Level 5 🎉

Du hast insgesamt 119 Nachrichten geschrieben.

Du hast <@&1024276691205496872> erhalten!

urban glen
solid ingot
#

if ID in self.afk

urban glen
#

mhm

#

beispiel:

self.afk = ['TIMOSID']

on message event

if TIMOSID in self.afk:
  await ctx.respond(f"Der ist gerade AFK.")
#

Dies that makes sense

solid ingot
#

probiers aus

urban glen
#

aber wie gette ich die ID die der user schickt? also das der typ den user pingt

solid ingot
urban glen
#

wow text

#

Ich weiß ja nd wie ich das in meinem code einbaue

#

xd

solid ingot
#

bei on_message

urban glen
#

ya

#

Kannst du kurz call ich verzweifle Blue_cry

solid ingot
#

morgen wieder

urban glen
#

okö

urban glen
#

Versteh den Fehler nicht ganz

quiet socket
#

Error: ```py
C:\Users\Georgi\AppData\Local\Programs\Python\Python311\python.exe "C:\Users\Georgi\Documents\Georgi\Developer stuff\PYTHON\EUROPE VERSE BOTS\SPACE X TEAM\main.py"
SPACE X TEAM#0782 ist online
Bot ID: 1078251854766538772
Bot Name: SPACE X TEAM
Bot Server: 1
Ignoring exception in command antwort bewerbung:
Traceback (most recent call last):
File "C:\Users\Georgi\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\core.py", line 124, in wrapped
ret = await coro(arg)
^^^^^^^^^^^^^^^
File "C:\Users\Georgi\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\core.py", line 976, in _invoke
await self.callback(self.cog, ctx, **kwargs)
File "C:\Users\Georgi\Documents\Georgi\Developer stuff\PYTHON\EUROPE VERSE BOTS\SPACE X TEAM\cogs\ticketcmds.py", line 43, in bewerbung
kanal = self.bot.get_channel(1078264391134347274)
^^^^^^^^
AttributeError: 'ticketcmds' object has no attribute 'bot'

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

Traceback (most recent call last):
File "C:\Users\Georgi\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\bot.py", line 1114, in invoke_application_command
await ctx.command.invoke(ctx)
File "C:\Users\Georgi\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\core.py", line 375, in invoke
await injected(ctx)
File "C:\Users\Georgi\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\core.py", line 124, in wrapped
ret = await coro(arg)
^^^^^^^^^^^^^^^
File "C:\Users\Georgi\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\core.py", line 1310, in _invoke
await command.invoke(ctx)
File "C:\Users\Georgi\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\core.py", line 375, in invoke
await injected(ctx)
File "C:\Users\Georgi\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\core.py", line 132, in wrapped
raise ApplicationCommandInvokeError(exc) from exc
discord.errors.ApplicationCommandInvokeError: Application Command raised an exception: AttributeError: 'ticketcmds' object has no attribute 'bot'

#

CODE:

#
import discord
from discord.ext import commands
from discord.commands import Option, SlashCommandGroup, slash_command

farbe = 0x2235a7


class ticketcmds(commands.Cog):
    def __int__(self, bot):
        self.bot = bot

    antwort = SlashCommandGroup("antwort", "Antworten auf Tickets")

    @antwort.command()
    @commands.has_role(947756404352098374)
    async def bewerbung(self, ctx,
                        auswahl: Option(choices=['Formular', 'Weiterleitung', 'Angenommen', 'Abgelehnt', 'Voll']),user: Option(discord.Member, description="User")):
        if auswahl == "Formular":
            formularbwembed = discord.Embed(title="Bewerbungsformular", description='''

:pfeilrechts: **__Dein Vorname + Alter__**
:offenerpunkt: Nenne uns dein Name und dein Alter 

:pfeilrechts:**__Warum genau dich?:__**
:offenerpunkt: Sag uns warum wir genau dich nehmen sollen.

 :pfeilrechts:__**Deine Stärken?:**__
:offenerpunkt: 5 Stärken und 5 Schwächen

:pfeilrechts:__**Über dich:**__
:offenerpunkt: Erzähle uns etwas über deine Freizeit ,deine Hobbys etc.

:pfeilrechts:__**Was willst du im Team erreichen?:**__
:offenerpunkt: Erzähle uns was du in unserem Team erreichen willst.''', color=farbe)
            formularbwembed.set_footer(text=f':copyright:{ctx.guild.name} 2023 ,All rights reserved.', icon_url=ctx.guild.icon.url)
            await ctx.send(f'{user.mention}',embed=formularbwembed)
            await ctx.respond("Bewerbungsformular wurde an den User gesendet",ephemeral=True)

        elif auswahl == "Weiterleitung":
            weiterleitungbw = discord.Embed(title="Bewerbung weitergeleitet", description='Deine Bewerbung wurde an unsere Teamleitung weitergeleitet', color=farbe)
            weiterleitungbw.set_footer(text=f':copyright:{ctx.guild.name} 2023 ,All rights reserved.', icon_url=ctx.guild.icon.url)
            weiterleitungbw.set_thumbnail(url=f'{user.avatar.url}')
            kanal = self.bot.get_channel(1078264391134347274)
            neuebewerbung = discord.Embed(title="Neue Bewerbung", description=f'{user.mention} hat sich beworben',
                                          color=farbe)
            neuebewerbung.add_field(name="User", value=f'{user.mention}')
            neuebewerbung.add_field(name="ID", value=f'{user.id}')
            neuebewerbung.add_field(name="Join Date", value=f'{user.joined_at}')
            neuebewerbung.add_field(name='Ticketchannel', value=f'{ctx.channel.mention}')
            neuebewerbung.set_thumbnail(url=f'{user.avatar.url}')
            await ctx.send(f'{user.mention}',embed=weiterleitungbw)
            await ctx.respond("Bewerbung wurde an die Teamleitung weitergeleitet",ephemeral=True)
            await kanal.send(embed=neuebewerbung)


def setup(bot):
    bot.add_cog(ticketcmds(bot))
#

ich habe ein bot objekt warum erkennt der das nicht?

quiet socket
#

?

solid ingot
solid ingot
urban glen
quiet socket
#

bzw wo lol

#

bin gerade bissen lost

solid ingot
dense magnet
#
def __int__(self, bot):

int = Integer
init = Initiator

quiet socket
#

oh danke :D

#

hat mir sehr weitergeholfen

vivid sky
#
Ignoring exception in command who:
Traceback (most recent call last):
  File "C:\Users\WorkHome\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\commands\core.py", line 124, in wrapped
    ret = await coro(arg)
  File "C:\Users\WorkHome\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\commands\core.py", line 974, in _invoke
    await self.callback(ctx, **kwargs)
  File "c:\Users\WorkHome\Desktop\baris\rdw1.py", line 257, in who
    avatar = await GetAvatar(ctx.author.id)
  File "c:\Users\WorkHome\Desktop\baris\rdw1.py", line 108, in GetAvatar
    idavatar = data[0]['avatarId']
KeyError: 0

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

Traceback (most recent call last):
  File "C:\Users\WorkHome\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\bot.py", line 1088, in invoke_application_command
    await ctx.command.invoke(ctx)
  File "C:\Users\WorkHome\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\commands\core.py", line 374, in invoke
    await injected(ctx)
  File "C:\Users\WorkHome\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\commands\core.py", line 132, in wrapped
    raise ApplicationCommandInvokeError(exc) from exc
discord.errors.ApplicationCommandInvokeError: Application Command raised an exception: KeyError: 0
#

i want to get help

wise stone
#

weil keyerror

vivid sky
#

ah okay habs eh schon gefixxt aber danke

storm seal
#

ein bot kann keine rich presence haben oder

solid ingot
#

nope

#

nur ne activity

visual swallow
#

Ich habe ein Fehler und zwar in Visual Studio Code steht import "discord" could not be resolved

#

Und ich py-cord ist noch nicht installiert

#

Aber der pip command geht auch nicht

#

Hier der Fehlercode

#

``pip : Die Benennung "pip" wurde nicht als Name eines Cmdlet, einer Funktion, einer Skriptdatei oder eines ausführbaren Programms erkannt. Überprüfen Sie die Schreibweise des Namens, oder ob der Pfad korrekt
ist (sofern enthalten), und wiederholen Sie den Vorgang.
In Zeile:1 Zeichen:1

  • pip install py-cord
  •   + CategoryInfo          : ObjectNotFound: (pip:String) [], CommandNotFoundException
      + FullyQualifiedErrorId : CommandNotFoundException``
mystic sentinel
#

was muss ich machen damit wenn der bot ausgewahlt wird das er dann was anderes sendet?

urban glen
#

Also du hast da ja if member == member.bot:, damit überprüfst du ja ob der member ein Bot is

storm seal
urban glen
storm seal
#

irgendwie mach ich trotzdem was falsch

visual swallow
#

Kann mir erstmal jemand bei meinen Fehler helfen?

urban glen
#

Was hast du als Prefix ausgewählt?

#

Musst regeln1 weiter zurück rücken

urban glen
#

Und du musst ja auch genauer erläutern, welcher Command nicht gefunden wird

storm seal
#

wie kann man nochmal anzeigen lassen auf wie vielen server den bot ist ?

solid ingot
#

len(self.bot.guilds)

storm seal
#

user dann auch so?

solid ingot
storm seal
#

len(self.bot.user)?

solid ingot
#

users

mystic flower
#

Code und error ka wieso der kommt xD

dense magnet
burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @dense magnet, du bist jetzt Level 15 🎉

Du hast insgesamt 877 Nachrichten geschrieben.

Du hast <@&1024276907136663562> erhalten!

mystic flower
dense magnet
#

Dann schick mal was du jetzt hast

mystic flower
#

Traceback (most recent call last):
File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\cog.py", line 780, in _load_from_module_spec
setup = getattr(lib, "setup")
AttributeError: module 'cogs.ticketcommnds' has no attribute 'setup'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "E:\VC\Own\tests\main.py", line 17, in <module>
bot.load_extension(f"cogs.{filename[:-3]}")
File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\cog.py", line 910, in load_extension
self._load_from_module_spec(spec, name)
File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\cog.py", line 783, in _load_from_module_spec
raise errors.NoEntryPointError(key)
discord.errors.NoEntryPointError: Extension 'cogs.ticketcommnds' has no 'setup' function.

Process finished with exit code 1

dense magnet
#

Nicht den Error

mystic flower
#

Hier

dense magnet
#

Ja das ist immernoch falsch eingerückt

#

Das muss ganz nach Links

mystic flower
#

xD

#

jo danke

cloud cedar
#

Bekomme diese Antwort von meiner API, wie kann ich da auf das value von den Bewertungen zugreifen?

"Ratings":[{"Source":"Internet Movie Database","Value":"8.4/10"}],"Metascore":"N/A","imdbRating":"8.4","imdbVotes":"269,464","imdbID":"tt13443470","Type":"series","totalSeasons":"1","Response":"True"}
mystic flower
#
Traceback (most recent call last):
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\cog.py", line 774, in _load_from_module_spec
    spec.loader.exec_module(lib)  # type: ignore
  File "<frozen importlib._bootstrap_external>", line 879, in exec_module
  File "<frozen importlib._bootstrap_external>", line 1017, in get_code
  File "<frozen importlib._bootstrap_external>", line 947, in source_to_code
  File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
  File "E:\VC\Own\Welcomer\cogs\Verfy.py", line 48
    def __init__(self,*args, **kwargs, client):
                                       ^^^^^^
SyntaxError: invalid syntax

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

Traceback (most recent call last):
  File "E:\VC\Own\Welcomer\main.py", line 16, in <module>
    bot.load_extension(f"cogs.{filename[:-3]}")
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\cog.py", line 910, in load_extension
    self._load_from_module_spec(spec, name)
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\cog.py", line 777, in _load_from_module_spec
    raise errors.ExtensionFailed(key, e) from e
discord.errors.ExtensionFailed: Extension 'cogs.Verfy' raised an error: SyntaxError: invalid syntax (Verfy.py, line 48)```
#

Das ist der error code kommt gleich

#

xD

#

liegt ja am client nur wenn ich bot mache kommt auch ein error

solid ingot
cloud cedar
#

achso, hab die [0] vergessen danke

solid ingot
#

die brauchst du aufgrund der liste

#

also diese [klammern]

cloud cedar
#

Yep
Nur dank deinem Tutorial hab ich überhaupt ne api peeposhy

burnt prairieBOT
#
Keks-Überweisung

@cloud cedar hat @solid ingot 1 keks geschenkt!

Timo hat jetzt 11,667 keks

mystic flower
#
Traceback (most recent call last):
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ui\view.py", line 414, in _scheduled_task
    await item.callback(interaction)
  File "E:\VC\Own\Welcomer\cogs\Verfy.py", line 44, in callback1
    await interaction.response.send_modal(verifyModal(title='Put in the correct code!'))
TypeError: verifyModal.__init__() missing 1 required positional argument: 'client'```
#

ohh okay

#
Ignoring exception in modal <cogs.Verfy.verifyModal object at 0x000001991DE114B0>:
Traceback (most recent call last):
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ui\modal.py", line 341, in dispatch
    await value.callback(interaction)
  File "E:\VC\Own\Welcomer\cogs\Verfy.py", line 69, in callback
    channel = self.client.get_channel(1075857268345679902)
AttributeError: 'verifyview' object has no attribute 'get_channel'
urban glen
#

self.interaction?

#

Nein.

mystic flower
#

xD

urban glen
mystic flower
mystic flower
urban glen
#

ok

#

Junge

#

Welchen Error

#

Welchen Code

#

Woher soll ich wissen wo du probleme hast

#

Wen du schreibst "nee dhelp"

#

Mach das Komma dahinter mal weg

#

geht's?

#

Wenn du ein Channel fetcht, musst du es awaiten

#

Soweit ich weiß

#

Tu das

#

?

#

Warum sollte es auch nicht funktionieren?

storm seal
torpid gorge
#

Hat irgendjemand eine Idee, wie man eine 2acc tracker machen könnte?

#

@solid ingot vielleicht du?

solid ingot
#

das ist ziemlich schwierig

torpid gorge
#

Ok

torpid gorge
torpid gorge
urban glen
torpid gorge
#

Warum frägst du?

urban glen
#

Wenn du jemanden Bannst und er nh 2 Acc erstellt und joined, wird er automatisch gebannt

#

Hab ich schon oft ausprobiert ._. xD

urban glen
# torpid gorge Ah ok

Aber du könntest halt überprüfen, ob der Account vor kurzem erstellt wurde, also maybe sowas, dass man nur joinen kann, wenn der Account eine Woche alt is oder so, is dir überlassen

torpid gorge
urban glen
dense magnet
#

So hab ich des gemacht

quiet socket
#

@torpid gorge du codest eine KI die das Verhalten von jedem einzelnen Mitglied analysiert und schon hast es.
Wenn es in der Datenbank ähnliche Verhaltensmuster gibt ban wenn nicht wird weiter geschaut.

storm seal
#

Weiß den einer was den grund ist und wie man das fixed ?diff -Application Command raised an exception: Forbidden: 403 Forbidden (error code: 50007): Cannot send messages to this user

#

oder brauch der bot recht in dev portal

tawdry leaf
#

ja der user hat die dms ausgestellt

solid ingot
#

oder der bot ist nicht auf einem server mit dem user

tawdry leaf
solid ingot
#

der user kann auch gefunden werden wenn er nicht auf demselben server ist

tawdry leaf
#

hm war bei mir noch nie so xD

tawdry leaf
storm seal
#

aber wenn das an ist müsste es doch gehen

normal sundial
#

hey, ich habe das problem dass mien bot wenn er bidler laden soll png lädt aber gif nicht er sucht sich die bilder selbst auf redit memes z.b und auch andere bilder wie katzen also ich habe keinen einfluss drauf was er grade anzeigt ist das normal?

#
@slash_command(description="sendet ein meme")
    async def meme(self, ctx):
        embed = discord.Embed(title="Meme!")
        async with aiohttp.ClientSession() as cs:
            async with cs.get('https://www.reddit.com/r/memes/new.json?sort=memes') as r:
                res = await r.json()
                embed.set_image(url=res['data']['children'][random.randint(0, 25)]['data']['url'])
                await ctx.respond(embed=embed)

der command

silk gulch
#

Also PNG's lädt er, aber GIF's nicht?
Werden denn alle angezeigt?

normal sundial
#

gifs nicht korrekt pngs werden angezeigt und die gifs wenn ich sie im browser öffne gehen aber im channel nicht

silk gulch
#

Gab doch eine Discord-Einstellung für. Möglicherweiße deswegen?

normal sundial
#

welche?

silk gulch
#

Naja gab doch meines Wissens eine Einstellung, womit GIFs auch direkt in Discord abgespielt werden.

#

Warte.

normal sundial
#

okay ich warte xD

silk gulch
#

Wird das bei dir abgespielt?

normal sundial
#

Ja

#

Kann es villeicht sein das die Websites mp4 als GIF ausgeben und da das Problem her kommt?

normal sundial
#

ist es auch normal das der bot so 10 mal in der nacht neustartet

urban glen
#

Außer du hast nh Scheduler gemacht

normal sundial
#

Ne okay dann liegt es vielleicht an meinem Internet

normal sundial
solid ingot
#

welche websites?

normal sundial
#

Der soll eigentlich von Reddit nehmen nimmt aber auch von zb. giphy

solid ingot
#

du schickst eine API anfrage an reddit aber bekommst eine antwort von giphy? 🤨

#

oder hat jemand ein giphy bild auf reddit gepostet und du bekommst das?

tough thicket
#

moin, ich wollte mal wieder VSC zum Coden verwenden, aber wenn ich ein neues Terminal öffne und dann dort pip freeze reinschreibe, dann kommt immer dieser Error:

pip : Die Benennung "pip" wurde nicht als Name eines Cmdlet, einer Funktion, einer Skriptdatei oder eines ausführbaren 
Programms erkannt. Überprüfen Sie die Schreibweise des Namens, oder ob der Pfad korrekt ist (sofern enthalten), und 
wiederholen Sie den Vorgang.
In Zeile:1 Zeichen:1
+ pip freeze
+ ~~~
    + CategoryInfo          : ObjectNotFound: (pip:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException
urban glen
tough thicket
urban glen
#

Den python 3.10 Interpreter vermute ich

tough thicket
#

bild vergessen anzuhängen

urban glen
#

Ja dann 3.9.13 wie es aussieht

tough thicket
#

habe ich bereits

tough thicket
#

pip freeze muss ich doch auch aber im Terminal ausführen nh?

uneven cedar
#

Ey
Weiß wer wie Mann ein giveaway starten kann wo Mann die Anvorderung hat wo Mann zum Beispiel 5 invites hat um Teilnehmern kann

urban glen
#

(^<^)

uneven cedar
#

Und mit welchen bot geht das

urban glen
#

Mit giveaway bots

uneven cedar
#

Ok weil hab ein und das geht ihrgend wie nicht

burnt prairieBOT
#

Mein Discord Server
https://discord.gg/zfvbjTEzv6

▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬▬
Mein Hosting* ► https://tidd.ly/3gJufg6
Code auf Github ► https://github.com/tibue99/tutorial-bot

PYCORD
Docs ► https://docs.pycord.dev/
Guide ► https://guide.pycord.dev/introduction/
Discord Server ► https://discord.gg/pycord

Discord Developer Portal ► https://discord...

▶ Play video
normal sundial
frail pewter
#
from discord.ext import commands


class Button(commands.Cog):
    def __init__(self, bot):
        self.bot = bot

    @commands.Cog.listener()
    async def on_ready(self):
        self.channel_id = 1074986909522198620


        channel = self.bot.get_channel(self.channel_id)
        await channel.send("Hier gehts zur Rollenauswahl:", view=TutorialView())




def setup(bot):
    bot.add_cog(Button(bot))



class TutorialView(discord.ui.View):
    def __init__(self):
        super().__init__(timeout=None)


        ps4_emoji = discord.PartialEmoji(id=1078924528140431420, name="ps4", animated=False)
        button1 = discord.ui.Button(label="Ps4", style=discord.ButtonStyle.primary, emoji=ps4_emoji, custom_id="ps4")
        self.add_item(button1)


        ps5_emoji = discord.PartialEmoji(id=1078924557576065084, name="ps5", animated=False)
        button2 = discord.ui.Button(label="Ps5", style=discord.ButtonStyle.primary, emoji=ps5_emoji, custom_id="ps5")
        self.add_item(button2)

    @discord.ui.button(custom_id="ps4_emoji")
    async def button_callback1(self, button, interaction):
        role_id = 1074989549878521886
        role = interaction.guild.get_role(role_id)
        member = interaction.user
        await member.add_roles(role)
        await interaction.response.send_message("Du hast die PS4 Rolle bekommen!", ephemeral=True)

    @discord.ui.button(custom_id="ps5_emoji")
    async def button_callback2(self, button, interaction):
        role_id = 1074989886047797348
        role = interaction.guild.get_role(role_id)
        member = interaction.user
        await member.add_roles(role)
        await interaction.response.send_message("Du hast die PS5 Rolle bekommen!", ephemeral=True)

Was mache ich falsch er sagt mir die ganze zeit das die Label fehlen aber die habe ich doch?

tough thicket
wise stone
#

ja

solid ingot
frail pewter
# solid ingot schick mal die genaue fehlermeldung

Ignoring exception in on_ready
Traceback (most recent call last):
File "C:\Users\admin\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\client.py", line 377, in _run_event
await coro(*args, **kwargs)
File "C:\Users\admin\PycharmProjects\Discord_bot\cogs\rollenauswahl.py", line 15, in on_ready
await channel.send("Hier gehts zur Rollenauswahl:", view=TutorialView())
File "C:\Users\admin\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\abc.py", line 1606, in send
data = await state.http.send_message(
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\admin\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\http.py", line 366, in request
raise HTTPException(response, data)
discord.errors.HTTPException: 400 Bad Request (error code: 50035): Invalid Form Body
In components.0.components.0.label: This field is required
In components.0.components.1.label: This field is required
In components.0.components.2.emoji.id: Invalid emoji
In components.0.components.3.custom_id: Component custom id cannot be duplicated

wise stone
#

gehe zum Google Übersetzer

#

und da steht was du machen sollst

frail pewter
wise stone
#

hat nichts mit emojis zu tun

#

da steht no Front custom_id

#

das es ein Duplikat gibt

#

das heißt die die id uniqe sein müssen

#

lern Englisch bruh

frail pewter
frail pewter
storm seal
#

Du weißt schon emojis werden auch in "" geschriebennerd

urban glen
#

ps5 --> ps5_emoji

frail pewter
#

Achse okay danke

frail pewter
burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @frail pewter, du bist jetzt Level 6 🎉

Du hast insgesamt 87 Nachrichten geschrieben.

storm seal
storm seal
#

nö nö

tough thicket
mystic flower
#

Weiß jemand wie ich ein member aus der hauptklasse in einen andere View Klasse übergeben kann also ich möchte machen das der member der das embed ausgelöst hat also ein on Message Event der member davon mit einem Button gebannt werden kann. Weiß wer wie das geht ?

mystic flower
#

Okay danke Timo

#

Aber ich will das ja nicht innerhalb einer Klasse sondern in zwei verschiedenen Klassen ist das dann auch so ?

#

@solid ingot

urban glen
solid ingot
#

wie meinst du das genau?

mystic flower
urban glen
#

Bruh ._.

mystic flower
storm seal
urban glen
lucid furnace
# urban glen <@1072983834519416893> Ist das so schwer??
Programms erkannt. Überprüfen Sie die Schreibweise des Namens, oder ob der Pfad korrekt ist (sofern enthalten), und wiederholen Sie den Vorgang.
In Zeile:1 Zeichen:1
+ ./Scripts/Activate.psl
+ ~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (./Scripts/Activate.psl:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException```
urban glen
#

Maybe geht's bei dir mit venv/bin/activate

lucid furnace
#

meinst du python -m venv .

urban glen
lucid furnace
#

nein

urban glen
#

Kannst auch so machen

#

Musst dafür virtualenv installieren

lucid furnace
urban glen
#

Schau dir ein Tutorial an

lucid furnace
#

ne du erklaärt es so scheisse

#

erst das video dan sagst du ich soll virtualenv instaliern

urban glen
#

In this video we learn how to create and use virtual environments in Python.

◾◾◾◾◾◾◾◾◾◾◾◾◾◾◾◾◾
📚 Programming Books & Merch 📚
🐍 The Python Bible Book: https://www.neuralnine.com/books/
💻 The Algorithm Bible Book: https://www.neuralnine.com/books/
👕 Programming Merch: https://www.neuralnine.com/shop

🌐 Social Media & Contact 🌐
📱 Website: https:/...

▶ Play video

Python is an amazing versatile coding language - and it's complimented by numerous different python packages and API's that you can incorporate into your workflow. However you can run into dependency errors and conflicts if you aren't managing your dependencies on a project specific level. VirtualEnv (venv) in Python is a package that allows the...

▶ Play video

Virtuelle #Python Umgebungen mit #virtualenv/#venv für Einsteiger erklärt: https://u-labs.de/portal/was-ist-eine-python-virtualenv-venv-und-wozu-braucht-man-sie-virtuelle-python-umgebung-fuer-einsteiger/ (Textversion mit allen Befehlen)

=== Mehr von U-Labs ===
U-Labs Portal (redaktionelle Artikel): https://u-labs.de/portal
U-Labs Community (Fra...

▶ Play video

Learn how create and use virtual environments in python using the built-in venv module.

If the video was helpful, let me know in the comments down below and also like the video so that other people can see it. Needles to say I really appreciate your support 💪❤️

📨 SUBSCRIBE so that you don't miss any new video:
https://www.youtube.com/c/FabioMu...

▶ Play video

Create Virtual Environment Visual Studio Code | Virtual Environment in Python
Using Python virtual environments from Visual Studio Code
Creating Virtual Environment for Python from VS Code
VS Code Setup with Python Virtual Environments
The Complete Guide to Python Virtual Environments!
Activate Python Virtual Environment in VSCode
THIS TOOK FORE...

▶ Play video
lucid furnace
urban glen
solid ingot
#

@urban glen denk immer dran nett zu bleiben. dasselbe gilt auch für dich @lucid furnace, nachrichten mit caps müssen nicht sein

vivid sky
#
@bot.slash_command(name="vdupe", description="Enables the venture dupe.")
async def add_vdupe(ctx):
    if isAccount(ctx.author.id):
        await relogin(ctx.author.id)

        if ctx.channel.type is discord.ChannelType.private:
            return await ctx.respond(f"Your try </vdupe:1078443800130756628> it on Dm's? bro :skull:")

        role = ctx.guild.get_role(1077675973497065552)
        if role not in ctx.author.roles:
            return await ctx.respond(f"You have not permission to make </vdupe:1078443800130756628> :skull:")


        for affenarsch in range(3):

            headers = {
                    "Content-Type": f"application/json",
                    "Authorization": f"Bearer {get_token(ctx.author.id)}"
                }

            data = json.dumps({})

            request = requests.post(
                    f"https://fortnite-public-service-prod11.ol.epicgames.com/fortnite/api/game/v2/profile/{get_idaccount(ctx.author.id)}/client/QueryProfile?profileId=theater2&rvn=-1",
                    headers=headers, data=data)
            data = json.loads(request.text)
            stuff = data['profileChanges'][0]['profile']['items']
            for i in stuff:
                if "building" in stuff[i]['templateId']:
                    orig = {"itemIds": [f"{i}"]}
                    body = json.dumps(orig)

                    # if items_dupe == []:
                    #     await ctx.respond('You have already activate Dupe.')
                    # else:
                    # payload = json.dumps({"itemIds": [items_dupe]})

                    requests.post(
                        f"https://fortnite-public-service-prod11.ol.epicgames.com/fortnite/api/game/v2/profile/{get_idaccount(ctx.author.id)}/client/DestroyWorldItems?profileId=theater2&rvn=-1",
                        headers=headers, data=body)
            embed = discord.Embed(title="Successful!",
                                          description=f"You added DupeV3 Ventures on [**`{get_display_name(ctx.author.id)}`**]",
                                          colour=discord.Color.green())
            avatar = await GetAvatar(ctx.author.id)
            embed.set_thumbnail(url=avatar)
            await asyncio.sleep(15)
            break
            await ctx.respond(embed=embed)
        else:
            embed = discord.Embed(title="❌ You are not logged in.",
                                  description=f"Type: </login:1057730832753754172> to Login",
                                  color=discord.Color.brand_red())
            await ctx.response.send_message(embed=embed, ephemeral=True)

Wie mache ich das das respond embed nur einmal reingesendet wird?

urban glen
vivid sky
urban glen
vivid sky
#

ja das habe ich schon zurück gerückt aber das else macht faxxen

urban glen
# vivid sky ja das habe ich schon zurück gerückt aber das else macht faxxen
@bot.slash_command(name="vdupe", description="Enables the venture dupe.")
async def add_vdupe(ctx):
    if isAccount(ctx.author.id):
        await relogin(ctx.author.id)

        if ctx.channel.type is discord.ChannelType.private:
            return await ctx.respond(f"Your try </vdupe:1078443800130756628> it on Dm's? bro :skull:")

        role = ctx.guild.get_role(1077675973497065552)
        if role not in ctx.author.roles:
            return await ctx.respond(f"You have not permission to make </vdupe:1078443800130756628> :skull:")

        for affenarsch in range(3):

            headers = {
                "Content-Type": f"application/json",
                "Authorization": f"Bearer {get_token(ctx.author.id)}"
            }

            data = json.dumps({})

            request = requests.post(
                f"https://fortnite-public-service-prod11.ol.epicgames.com/fortnite/api/game/v2/profile/{get_idaccount(ctx.author.id)}/client/QueryProfile?profileId=theater2&rvn=-1",
                headers=headers, data=data)
            data = json.loads(request.text)
            stuff = data['profileChanges'][0]['profile']['items']
            for i in stuff:
                if "building" in stuff[i]['templateId']:
                    orig = {"itemIds": [f"{i}"]}
                    body = json.dumps(orig)

                    # if items_dupe == []:
                    #     await ctx.respond('You have already activate Dupe.')
                    # else:
                    # payload = json.dumps({"itemIds": [items_dupe]})

                    requests.post(
                        f"https://fortnite-public-service-prod11.ol.epicgames.com/fortnite/api/game/v2/profile/{get_idaccount(ctx.author.id)}/client/DestroyWorldItems?profileId=theater2&rvn=-1",
                        headers=headers, data=body)
            embed = discord.Embed(title="Successful!",
                                  description=f"You added DupeV3 Ventures on [**`{get_display_name(ctx.author.id)}`**]",
                                  colour=discord.Color.green())
            avatar = await GetAvatar(ctx.author.id)
            embed.set_thumbnail(url=avatar)
            await asyncio.sleep(15)
            break 
        await ctx.respond(embed=embed)
    else:
        embed = discord.Embed(title="❌ You are not logged in.",
                                description=f"Type: </login:1057730832753754172> to Login",
                                color=discord.Color.brand_red())
        await ctx.response.send_message(embed=embed, ephemeral=True)

Probiers so

#

Dein else mit dem "You are not logged in." war nicht unter dem richtigen if statement

vivid sky
#
Ignoring exception in command vdupe:
Traceback (most recent call last):
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\commands\core.py", line 124, in wrapped
    ret = await coro(arg)
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\commands\core.py", line 980, in _invoke
    await self.callback(ctx, **kwargs)
  File "C:\Users\bobby\PycharmProjects\pythonProject1\main.py", line 384, in add_vdupe
    await ctx.respond(embed=embed)
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\commands\context.py", line 282, in respond
    return await self.interaction.response.send_message(
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\interactions.py", line 825, in send_message
    await self._locked_response(
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\interactions.py", line 1090, in _locked_response
    await coro
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\webhook\async_.py", line 215, in request
    raise NotFound(response, data)
discord.errors.NotFound: 404 Not Found (error code: 10062): Unknown interaction

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

Traceback (most recent call last):
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\bot.py", line 1114, in invoke_application_command
    await ctx.command.invoke(ctx)
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\commands\core.py", line 375, in invoke
    await injected(ctx)
  File "C:\Users\bobby\PycharmProjects\pythonProject1\venv\lib\site-packages\discord\commands\core.py", line 132, in wrapped
    raise ApplicationCommandInvokeError(exc) from exc
discord.errors.ApplicationCommandInvokeError: Application Command raised an exception: NotFound: 404 Not Found (error code: 10062): Unknown interaction
urban glen
#

Wait

#

ich schaus mir gleich an

urban glen
# vivid sky ```py Ignoring exception in command vdupe: Traceback (most recent call last): ...
@bot.slash_command(name="vdupe", description="Enables the venture dupe.")
async def add_vdupe(ctx):
    if isAccount(ctx.author.id):
        await relogin(ctx.author.id)

        if ctx.channel.type is discord.ChannelType.private:
            return await ctx.respond(f"Your try </vdupe:1078443800130756628> it on Dm's? bro :skull:")

        role = ctx.guild.get_role(1077675973497065552)
        if role not in ctx.author.roles:
            return await ctx.respond(f"You have not permission to make </vdupe:1078443800130756628> :skull:")

        for affenarsch in range(3):

            headers = {
                "Content-Type": f"application/json",
                "Authorization": f"Bearer {get_token(ctx.author.id)}"
            }

            data = json.dumps({})

            request = requests.post(
                f"https://fortnite-public-service-prod11.ol.epicgames.com/fortnite/api/game/v2/profile/{get_idaccount(ctx.author.id)}/client/QueryProfile?profileId=theater2&rvn=-1",
                headers=headers, data=data)
            data = json.loads(request.text)
            stuff = data['profileChanges'][0]['profile']['items']
            for i in stuff:
                if "building" in stuff[i]['templateId']:
                    orig = {"itemIds": [f"{i}"]}
                    body = json.dumps(orig)

                    # if items_dupe == []:
                    #     await ctx.respond('You have already activate Dupe.')
                    # else:
                    # payload = json.dumps({"itemIds": [items_dupe]})

                    requests.post(
                        f"https://fortnite-public-service-prod11.ol.epicgames.com/fortnite/api/game/v2/profile/{get_idaccount(ctx.author.id)}/client/DestroyWorldItems?profileId=theater2&rvn=-1",
                        headers=headers, data=body)
                    await asyncio.sleep(0.5)
                    break
        embed = discord.Embed(title="Successful!",
                              description=f"You added DupeV3 Ventures on [**`{get_display_name(ctx.author.id)}`**]",
                              colour=discord.Color.green())
        avatar = await GetAvatar(ctx.author.id)
        embed.set_thumbnail(url=avatar)
        await ctx.respond(embed=embed)
    else:
        embed = discord.Embed(title="❌ You are not logged in.",
                              description=f"Type: </login:1057730832753754172> to Login",
                              color=discord.Color.brand_red())
        await ctx.response.send_message(embed=embed, ephemeral=True)
#

Is halt schwer so über discord grad zu machen

vivid sky
#

gleicher fehler

viscid lake
#

wie bekommt man python interpreter

urban glen
viscid lake
urban glen
#

pycharm?

viscid lake
#

ja klar

urban glen
#

This is the Getting Started Series, with Paul Everitt.

In this episode, you will learn how to create local interpreters in PyCharm with Virtualenv, PipEnv, Conda, and the system interpreter.

0:00 - Intro
1:28 - New interpreter
2:53 - Virtualenv
3:48 - Pinenv
4:18 - Conda
5:08 - Existing interpreter
6:14 - Cloning a project
7:43 - Changing the ...

▶ Play video
viscid lake
urban glen
urban glen
viscid lake
#

danke aber ich kann kein englisch deswegen frag ich ja hier

viscid lake
urban glen
viscid lake
#

ka habs immer runtergeladen sonst musste ich nichts machen

urban glen
viscid lake
#

du kannst schon lesen oder

#

naja ich frag eif wo anderes xd

tough thicket
#

@urban glen habe ja auch das Interpreter Problem.

urban glen
urban glen
viscid lake
#

bruder

tough thicket
viscid lake
#

tust du meine nachricht eig lesen??????

urban glen
urban glen
viscid lake
#

danke aber ich kann kein englisch deswegen frag ich ja hierdanke aber ich kann kein englisch deswegen frag ich ja hierdanke aber ich kann kein englisch deswegen frag ich ja hierdanke aber ich kann kein englisch deswegen frag ich ja hierdanke aber ich kann kein englisch deswegen frag ich ja hierdanke aber ich kann kein englisch deswegen frag ich ja hierdanke aber ich kann kein englisch deswegen frag ich ja hier

#

lesen

urban glen
tough thicket
viscid lake
#

xd

#

hab vergessen das da alles auf englisch ist stimmt

#

omg bist du dumm...

urban glen
urban glen
tough thicket
#

anscheinend

#

wie kann ich das jetzt beheben?

urban glen
urban glen
urban glen
#

oder komm talk, dann kann ich's mir mal so anschauen

#

Können dann #1020759567421931620

tough thicket
#

nur py -m pip freeze

#

dann zeigt er mir das auch alles an

#

xD

urban glen
#

@solid ingot was willst du eig mit der Seite jetzt machen?
https://keksbot.xyz/

Du könntest da doch so Infos und sowas machen und vlt deinen discord server auch verlinken und so

#

Lol, falscher Channel

#

xD

mystic flower
#
Ignoring exception in on_message
Traceback (most recent call last):
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 377, in _run_event
    await coro(*args, **kwargs)
  File "D:\VC\Own\Welcomer\cogs\antilink.py", line 40, in on_message
    await channel.send(embed=logembed, view=buttonview(self.bot, message.author))
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\abc.py", line 1622, in send
    state.store_view(view, ret.id)
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\state.py", line 386, in store_view
    self._view_store.add_view(view, message_id)
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ui\view.py", line 582, in add_view
    view._start_listening_from_store(self)
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ui\view.py", line 425, in _start_listening_from_store
    self.__timeout_expiry = time.monotonic() + self.timeout
TypeError: unsupported operand type(s) for +: 'float' and 'Button'```
lucid furnace
mystic flower
#
Ignoring exception in on_message
Traceback (most recent call last):
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\client.py", line 377, in _run_event
    await coro(*args, **kwargs)
  File "D:\VC\Own\Welcomer\cogs\antilink.py", line 40, in on_message
    await channel.send(embed=logembed, view=buttonview(self.bot, message.author))
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\abc.py", line 1622, in send
    state.store_view(view, ret.id)
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\state.py", line 386, in store_view
    self._view_store.add_view(view, message_id)
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ui\view.py", line 582, in add_view
    view._start_listening_from_store(self)
  File "C:\Users\pogod\AppData\Local\Programs\Python\Python310\lib\site-packages\discord\ui\view.py", line 425, in _start_listening_from_store
    self.__timeout_expiry = time.monotonic() + self.timeout
TypeError: unsupported operand type(s) for +: 'float' and 'Button'```
#
class buttonview(discord.ui.View):
    def __init__(self, bot, user):
        self.bot = bot
        self.user = user
        super().__init__(timeout=None)

    @discord.ui.button(label="ban", style=discord.ButtonStyle.green)
    async def ban(self, button: discord.ui.Button, interaction: discord.Interaction):
        await interaction.response.send_message("Banned", ephemeral=True)
        await self.user.ban(reason="Antilink")

    @discord.ui.button(label="kick", style=discord.ButtonStyle.red)
    async def kick(self, button: discord.ui.Button, interaction: discord.Interaction):
        await interaction.response.send_message("Kicked", ephemeral=True)
        await self.user.kick(reason="Antilink")

    @discord.ui.button(label="timeout", style=discord.ButtonStyle.grey)
    async def timeout(self, button: discord.ui.Button, interaction: discord.Interaction):
        await interaction.response.send_message("Timeout",view= antilinktimeout , ephemeral=True)```
#
                channel = await self.bot.fetch_channel(1078689394627715113)
                logembed = discord.Embed(title="Anti-Link", description=f"{message.author.mention} tried to send a link in {message.channel.mention}")
                logembed.add_field(name="Message", value=f"||{message.content}||", inline=True)
                logembed.add_field(name="User", value=f"||{message.author.mention}||", inline=True)
                logembed.add_field(name="ID", value=f"||{message.author.id}||", inline=True)
                await channel.send(embed=logembed, view=buttonview(self.bot, message.author))
                await message.delete()
                await message.channel.send(f"{message.author.mention} Links aren't allowed here!", delete_after=5)```
urban glen
#

Bin grad am handy

urban glen
burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @past temple, du bist jetzt Level 28 🎉

Du hast insgesamt 3,820 Nachrichten geschrieben.

mental hamlet
#

so irt das verwirrend

mystic flower
#

war in timos video so

urban glen
#

Also in klammern

mystic flower
#

okay

#

wart ich teste es

#

ne gleicher error

mystic flower
urban glen
#

Wait

mystic flower
#

jop

urban glen
#

Muss mich konzentrieren, bin am scheißen hahahah

mystic flower
#

xD

#

haha

storm seal
#

🧢

urban glen
urban glen
#

Kurz zum test

mystic flower
#

ja wrate

#

warte

mystic flower
urban glen
#

Ahhhhhh

#

Jetzt seh ivhs

#

Kannst wieder timeout=None hinmachen

mystic flower
#

hab ich jetzt

urban glen
#

Mach async def _timeout

mystic flower
#

uff

urban glen
#

Weil das ding darfst du nicht als timeout definieren

mystic flower
#

ja

#

geht jetzt danke peepoheart

urban glen
#

Kein ding

mystic flower
urban glen
#

Schick mal code von antilinktimeout

mystic flower
#
class antilinktimeout(discord.ui.Select):
    def __init__(self, user):
        self.user = user
        super().__init__()

    @discord.ui.select(
        placeholder="Select an option",
        min_values=1,
        max_values=1,
        options=options

    )
    async def select_timeout(self, select: discord.ui.Select, interaction: discord.Interaction):
        if "1" in select.values:
            await interaction.response.send_message("1 minute", ephemeral=True)
        elif "5" in select.values:
            await interaction.response.send_message("5 minutes", ephemeral=True)
        elif "10" in select.values:
            await interaction.response.send_message("10 minutes", ephemeral=True)
        elif "15" in select.values:
            await interaction.response.send_message("15 minutes", ephemeral=True)
        elif "30" in select.values:
            await interaction.response.send_message("30 minutes", ephemeral=True)

urban glen
#

Als screenshot

#

Hilft das maybe

#

Ein dropdown is eig anders aufgebaut, soweit ich weiß

#

Also nd so wie bei dir, kann mich aber auch irren

#
class antilinktimeout(discord.ui.Select):
    def __init__(self, user):
        self.user = user
  
        options = [] # deine options
 
        super().__init__(
        placeholder="Select an option",
        min_values=1,
        max_values=1,
        options=options

    )
    async def select_timeout(self, select: discord.ui.Select, interaction: discord.Interaction):
        if "1" in select.values:
            await interaction.response.send_message("1 minute", ephemeral=True)
        elif "5" in select.values:
            await interaction.response.send_message("5 minutes", ephemeral=True)
        elif "10" in select.values:
            await interaction.response.send_message("10 minutes", ephemeral=True)
        elif "15" in select.values:
            await interaction.response.send_message("15 minutes", ephemeral=True)
        elif "30" in select.values:
            await interaction.response.send_message("30 minutes", ephemeral=True)

#

So ungefähr

#

Is jetzt halt schwer am Handy

mystic flower
#

okay

tawdry leaf
tawdry leaf
urban glen
tawdry leaf
mystic flower
mystic flower
# tawdry leaf Oki
AttributeError: 'timeoutselect' object has no attribute 'to_components' ``` 
Ich verstehe den error nicht
#
class timeoutselect(discord.ui.Select):
    def __init__(self):
        super().__init__(
            min_values=1,
            max_values=1,
            placeholder="Triff eine Auswahl",
            options=options
        )

    async def callback(self, interaction):
        await interaction.response.send_message(f"Du hast {self.values[0]} gewählt")




def setup(bot):
    bot.add_cog(antilink(bot))
tawdry leaf
#

Lern mal error lesen

mystic flower
#

#

bin lost

tawdry leaf
#

Frag Chat gpt da ist eine gute Erklärung dabei

urban glen
#

Du musst es zu einer View klasse hinzufügen

mystic flower
#

okay

tawdry leaf
mystic flower
#

und wie ?

#

xD

tawdry leaf
#

Müssen weiß ich jz nicht

tawdry leaf
urban glen
#

class DropdownView(discord.ui.View):
    def __init__(self, user):
        self.user = user
        super().__init__()

        self.add_item(timeoutselect(self.user))
mystic flower
#

okay

tawdry leaf
#

😁

urban glen
# mystic flower

Musst halt dann antilinktimeout() -> DropdownView(self.user) machen

urban glen
#

Ich hab bloß nh vorlage geliefert

tawdry leaf
#

So lernt er es aber nicht selber 😁

urban glen
#

Von der offiziellen seite

tawdry leaf
#

Wenn du des mit View weg gelassen hättest würde der Code kein View Class brauchen.

tawdry leaf
#

Du lernst so das nie

mystic flower
#

ja

urban glen
tawdry leaf
scenic hazel
#

Guten Abend zusammen,
Ich verstehe nicht welches Argument zu viel ist. Das ist das Innenleben des cogs:

import discord
import discord.ui
import datetime
from discord.ext import commands

class bank(commands.cog):
    async def __init__(self, client):
        self.client = client


    @commands.command
    async def bank(self, ctx):
        embed = discord.Embed(description="",
                              color=0x2adbc9,
                              timestamp=datetime.datetime.utcnow())
        
        embed.set_footer(text="Cosmany Hilfesystem",
                         icon_url=self.client.user.avatar)
        
        embed.add_field(name="Cosmany Bankverbindung",
                        value="Empfänger: Cosmany e.V.\nIBAN: DEXX XXXX XXXX XX\nVerwendungszweck: [Mitglieds-ID]",
                        inline=False)
        
        await ctx.reply(embed=embed, mention_author=False)
    

def setup(client):
    client.add_cog(bank(client))
burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @scenic hazel, du bist jetzt Level 2 🎉

Du hast insgesamt 7 Nachrichten geschrieben.

Du hast <@&1042123300970696705> erhalten!

storm seal
#

@urban glen du machst doch eine website mit python oder?

urban glen
#

Warum?

storm seal
#

weil ich mein dc profile bild in eine website mit rein machen möchte aber halt auch so das es immer aktualisiert wird wenn ich es änder

solid ingot
scenic hazel
#

uff übersehen so simpel xD danke^^

solid ingot
#

gerne

solid ingot
#

bei isinstance musst du beide sachen, die du vergleichen willst, in die runden klammern schreiben

mystic flower
#

musts self übergeben bzw bei mir hat das so funktioniert

burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @mystic flower, du bist jetzt Level 10 🎉

Du hast insgesamt 423 Nachrichten geschrieben.

Du hast <@&1032921984612433952> erhalten!

mystic flower
#

self

#

downloaden xD

#

und reinkopieren

#

kein problem

#

yea

#

Geht es ?

#

mach das

#

bei mir gings

#

nvm auch nicht

#

dann ka was da los ist

solid ingot
#

welcher error kommt denn jetzt?

solid ingot
#

der error dürfe nichts dem mute command zu tun haben

#

wenn du nur slash commands nutzt, kannst du discord.Bot statt commands.Bot verwenden um den error zu vermeiden

#

achso das sind 2 verschiedene errors

#

braucht dein bot vlt länger als 3 sekunden zum antworten?

lucid furnace
#
  File "c:\Programieren\Neuer Ordner\cogs\music.py", line 3, in <module>
    from discord.commands import slash_command, Option, SlashCommandGroup, OptionChoice
  File "C:\Users\carol\Documents\anaconda3\lib\site-packages\discord\commands\__init__.py", line 27, in <module>
    from .core import *
  File "C:\Users\carol\Documents\anaconda3\lib\site-packages\discord\commands\core.py", line 49, in <module>
    from ..enums import MessageType, SlashCommandOptionType, try_enum
ImportError: cannot import name 'SlashCommandOptionType' from 'discord.enums' (C:\Users\carol\Documents\anaconda3\lib\site-packages\discord\enums.py)```
#

ich krieg immer random errors seit dem ich nextcord installiert habe

solid ingot
#

sieht so aus als wäre etwas falsch installiert worden

limpid wolf
lucid furnace
#

wie fix ich das

urban glen
#

xD

limpid wolf
#

Pycord >>>

lucid furnace
#

ne

limpid wolf
lucid furnace
#

pycord on top

limpid wolf
lucid furnace
#

Import "discord.utils" could not be resolved

limpid wolf
#

Ich glaube Utils muss groß geschrieben werden

#

Bin mir aber nicht sicher

mental hamlet
#

ALSO, es gibt keine bessere Library, beide sind gut beide haben ihre Fehler und Vor- Nachteile ALSO HÖRT AUF zu sagen Pycord ist besser, das stimmt schlichtweg nicht auch können viele hier das nicht beurteilen da sie einfach voreingenommen sind und gar nichts neues probieren wollen / zu wenig Erfahrung haben um so etwas sagen zu können.

lucid furnace
#

nope nix anders

limpid wolf
lucid furnace
#

fr

mental hamlet
#

Was machst du dann peeposus

urban glen
mental hamlet
#

Ich wollte das jetzt einmal gesagt haben und kann darum dann immer verweisen

#

Und naja es nervt einfach dauerhaft dieses ja x ist besser als y zu sehen

lucid furnace
limpid wolf
urban glen
limpid wolf
urban glen
limpid wolf
#

Bin mir nt genau sicher

lucid furnace
#

hab ich schon macht nix

mental hamlet
burnt prairieBOT
#
Level Up!

Herzlichen Glückwunsch @mental hamlet, du bist jetzt Level 17 🎉

Du hast insgesamt 1,229 Nachrichten geschrieben.

urban glen
limpid wolf
mental hamlet
#

Hat damit auch nix zu tun, Voice hat nix mit utils zu tun

#

Utils sind schon in der base lib drin

#

Bzw. die neueste Version

urban glen
lucid furnace
#
Collecting discord
  Using cached discord-2.1.0-py3-none-any.whl (1.1 kB)
Collecting discord.py>=2.1.0
  Using cached discord.py-2.1.1-py3-none-any.whl (1.1 MB)
Collecting aiohttp<4,>=3.7.4
  Using cached aiohttp-3.8.4-cp39-cp39-win_amd64.whl (323 kB)
Requirement already satisfied: multidict<7.0,>=4.5 in c:\users\carol\documents\anaconda3\lib\site-packages (from aiohttp<4,>=3.7.4->discord.py>=2.1.0->discord) (6.0.4)
Collecting aiosignal>=1.1.2
  Using cached aiosignal-1.3.1-py3-none-any.whl (7.6 kB)
Collecting async-timeout<5.0,>=4.0.0a3
  Using cached async_timeout-4.0.2-py3-none-any.whl (5.8 kB)
Collecting frozenlist>=1.1.1
  Using cached frozenlist-1.3.3-cp39-cp39-win_amd64.whl (34 kB)
Requirement already satisfied: yarl<2.0,>=1.0 in c:\users\carol\documents\anaconda3\lib\site-packages (from aiohttp<4,>=3.7.4->discord.py>=2.1.0->discord) (1.8.2)
Collecting attrs>=17.3.0
  Using cached attrs-22.2.0-py3-none-any.whl (60 kB)
Collecting charset-normalizer<4.0,>=2.0
  Using cached charset_normalizer-3.0.1-cp39-cp39-win_amd64.whl (96 kB)
Collecting idna>=2.0
  Using cached idna-3.4-py3-none-any.whl (61 kB)
Installing collected packages: charset-normalizer, idna, frozenlist, attrs, async-timeout, aiosignal, aiohttp, discord.py, discord
ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
twisted 22.2.0 requires Automat>=0.8.0, which is not installed.
twisted 22.2.0 requires constantly>=15.1, which is not installed.
twisted 22.2.0 requires hyperlink>=17.1.1, which is not installed.
twisted 22.2.0 requires incremental>=21.3.0, which is not installed.
tldextract 3.2.0 requires filelock>=3.0.8, which is not installed.
service-identity 18.1.0 requires cryptography, which is not installed.
scrapy 2.6.2 requires cryptography>=2.0, which is not installed.```
#
scrapy 2.6.2 requires cssselect>=0.9.1, which is not installed.
scrapy 2.6.2 requires itemadapter>=0.1.0, which is not installed.
scrapy 2.6.2 requires itemloaders>=1.0.1, which is not installed.
requests 2.28.1 requires certifi>=2017.4.17, which is not installed.
pytest 7.1.2 requires atomicwrites>=1.0, which is not installed.
pytest 7.1.2 requires colorama, which is not installed.
pytest 7.1.2 requires iniconfig, which is not installed.
panel 0.13.1 requires bleach, which is not installed.
panel 0.13.1 requires bokeh<2.5.0,>=2.4.0, which is not installed.
requests 2.28.1 requires charset-normalizer<3,>=2, but you have charset-normalizer 3.0.1 which is incompatible.
Successfully installed aiohttp-3.8.4 aiosignal-1.3.1 async-timeout-4.0.2 attrs-22.2.0 charset-normalizer-3.0.1 discord-2.1.0 discord.py-2.1.1 frozenlist-1.3.3 idna-3.4```
mental hamlet
#

Metafrage xD

urban glen
#

ey diese scheisse ich krieg immer noch dass gleiche C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: discord.py is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall discord.py` warn(message, DistributionWarning, stacklevel=0) C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: discord is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall discord` warn(message, DistributionWarning, stacklevel=0) C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: py-cord is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall py-cord` warn(message, DistributionWarning, stacklevel=0) Traceback (most recent call last): File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 741, in _load_from_module_spec spec.loader.exec_module(lib) # type: ignore ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap_external>", line 940, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "C:\Programieren\Neuer Ordner\cogs\music.py", line 3, in <module> from discord.commands import slash_command, Option, SlashCommandGroup, OptionChoice File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\__init__.py", line 26, in <module> from .context import * File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\context.py", line 29, in <module> import discord.abc File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\abc.py", line 7, in <module>

#
    from nextcord.abc import (
ImportError: cannot import name '_Undefined' from 'nextcord.abc' (C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\abc.py)

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

Traceback (most recent call last):
  File "C:\Programieren\Neuer Ordner\main.py", line 24, in <module>
    bot.load_extension(f"cogs.{filename[:-3]}")
  File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 863, in load_extension
    self._load_from_module_spec(spec, name, extras=extras)
  File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 744, in _load_from_module_spec
    raise errors.ExtensionFailed(key, e) from e
nextcord.ext.commands.errors.ExtensionFailed: Extension 'cogs.music' raised an error: ImportError: cannot import name '_Undefined' from 'nextcord.abc' (C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\abc.py)```
#

ich hab aber nextcord nicht installiert

mental hamlet
#

Wieso importierst du es dann

urban glen
#

hab ich nict

mental hamlet
#

Dein error sagt was anderes

urban glen
#

warte ich zeig dir ss

#

das ist alles

urban glen
urban glen
#

Du sollst keine Metafragen stellen

#

*Was ist das?

#

Es gibt da so nh schöne seite, sie heißt metafrage.de

Da wirds dir erklärt

#

Bro is in deinem verstand noch alles okay?

tawdry leaf
#

hmm stimmt wirklich

urban glen
#

Vorallem, ich kann einfach widerlegen was er sagt ..:..:..

#

Omg diese Generation ist verloren…

#

kann mir wer helfen

tawdry leaf
#

wo ist code

urban glen
#

Toll, zu mir sagt chatgpt beleidigungen, und jetzt?

limpid wolf
urban glen
urban glen
#

digga was ist nh meta frage

#

ich geh nicht auf ner random website

#

Uff ich geb es bei euch auf

#

Nein!!

limpid wolf
# urban glen ich geh nicht auf ner random website
Eine Metafrage ist eine Frage über eine Frage, wie beispielsweise „Darf ich etwas fragen?“ oder „Kennt sich jemand mit Computern aus?“.

In der Regel wird der Begriff Metafrage aber verallgemeinert und damit alle Fragen bezeichnet, die keine direkte Frage zum Problem des Hilfesuchenden sind. Der Hilfesuchende fragt also zunächst allgemein, ob jemand helfen kann. Gerade Neulinge oder unerfahrene Benutzer lassen sich zu Metafragen hinreißen, um einen kompetenten und hilfsbereiten Ansprechpartner zu finden. Meistens werden Metafragen ignoriert oder der Fragende wird rüde darauf hingewiesen, dass ihm niemand bei seinem Problem helfen könne, ohne dies zu kennen. Grundsätzlich folgt auf eine Meta-Frage eine weitere Frage.


Vorteile von Metafragen
als höfliche Floskel um Aufmerksamkeit zu gewinnen
Beginn einer zunächst einseitigen Konversation (Allgemeine Problemanalyse)

Nachteile von Metafragen
die Anwesenden könnten eventuell bei dem Problem helfen, obwohl sie (eventuell aus Bescheidenheit) nicht von sich behaupten würden, mit dem Thema vertraut zu sein,
oft ist die Metafrage falsch formuliert, z. B. wird gefragt „kennt sich jemand mit Kochen aus?“ und er will nur wissen, ob Mangos essbar sind,
Auch wenn jemand mit dem erfragten Thema vertraut ist, bedeutet dies nicht, dass er eine spezielle Frage zu diesem beantworten kann – niemand ist allwissend,
wenn keine Reaktion auf die Metafrage erfolgt, beläßt es der Fragende meist dabei. So kann eine Antwort auf das Problem von später aufmerksam Werdenden nicht erfolgen.

Beispiele
„Kennt sich jemand mit Computern aus?“
„Kann mir jemand helfen?“
„Kann ich dich mal sprechen?“
„Darf ich euch was fragen?“
„Kann mir jemand mit FTP-Servern helfen?“
„Ist hier zufällig jemand, der sich mit Scheidungen auskennt?"
„Hast du Zeit?“
„Kannst du mal herkommen?“

Weblinks
Smart Questions: Wie man Fragen in Foren, Chatrooms und Mailinglisten stellt, um befriedigende Antworten zu erhalten.```
tawdry leaf
urban glen
#

Junge ChatGPT kann nicht immer eure Probleme lösen, zumal da nicht immer vieles richtig ist

#

wie soll ich sonst fragen hää

tawdry leaf
#

ist halt basierend auf 2021 🙂

#

2 jahre veraltet was erwartest du

#

stackoverflow ist besser

limpid wolf
tawdry leaf
limpid wolf
#

Auf "kann mir wer helfen" wirst du keine antwort bekommen

urban glen
#

@urban glen du kannst es so fragen, indem du direkt code + error schickst und eine gute Problembeschreibung hinzugefügst

tawdry leaf
#

*hinzufügst

limpid wolf
urban glen
#

@limpid wolf @tawdry leaf

Ich gebe es mit den beiden auf, bin weg

*und ihr solltet das auch tun

#

Haut rein

tawdry leaf
#

Am besten einf Talk kommen da wird immer geholfen

tawdry leaf
urban glen
#

C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: discord.py is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall discord.py` warn(message, DistributionWarning, stacklevel=0) C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: discord is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall discord` warn(message, DistributionWarning, stacklevel=0) C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: py-cord is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall py-cord` warn(message, DistributionWarning, stacklevel=0) Traceback (most recent call last): File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 741, in _load_from_module_spec spec.loader.exec_module(lib) # type: ignore ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap_external>", line 940, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "C:\Programieren\Neuer Ordner\cogs\music.py", line 3, in <module> from discord.commands import slash_command, Option, SlashCommandGroup, OptionChoice File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\__init__.py", line 26, in <module> from .context import * File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\context.py", line 29, in <module> import discord.abc File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\abc.py", line 7, in <module> from nextcord.abc import (

#
ImportError: cannot import name '_Undefined' from 'nextcord.abc' (C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\abc.py)

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

Traceback (most recent call last):
  File "C:\Programieren\Neuer Ordner\main.py", line 24, in <module>
    bot.load_extension(f"cogs.{filename[:-3]}")
  File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 863, in load_extension
    self._load_from_module_spec(spec, name, extras=extras)
  File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 744, in _load_from_module_spec
    raise errors.ExtensionFailed(key, e) from e
nextcord.ext.commands.errors.ExtensionFailed: Extension 'cogs.music' raised an error: ImportError: cannot import name '_Undefined' from 'nextcord.abc' (C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\abc.py)```
tawdry leaf
#

und dein code

limpid wolf
#

uh nextcord @urban glen du bist gefragt haha

tawdry leaf
#

hahahaha

urban glen
urban glen
#

Macht selber

limpid wolf
tawdry leaf
urban glen
tawdry leaf
tawdry leaf
#

Twevis goat was mit deinem error jz

urban glen
#
import discord
import os
from discord.ext import commands

intents = discord.Intents.default()

bot = commands.Bot(
    intents=intents,
)


@bot.event
async def on_ready():
    os.system("cls")
    os.system("title Discord Bot")
    os.system("color 0a")
    os.system("cls")
    print(f"{bot.user} is online")


if __name__ == "__main__":
    for filename in os.listdir("cogs"):
        if filename.endswith(".py"):
            bot.load_extension(f"cogs.{filename[:-3]}")

    bot.run(sag ich nd)```
tawdry leaf
#

joa also

#
import discord
import os
from discord.ext import commands

intents = discord.Intents.default()

bot = commands.Bot(
    intents=intents,
)


@bot.event
async def on_ready():
    os.system("cls")
    os.system("title Discord Bot")
    os.system("color 0a")
    os.system("cls")
    print(f"{bot.user} is online")


    if __name__ == "__main__":
      for filename in os.listdir("cogs"):
          if filename.endswith(".py"):
              bot.load_extension(f"cogs.{filename[:-3]}")

bot.run('sag ich nd')```
urban glen
#

wo isst der untershied

tawdry leaf
#

einrückung

urban glen
#

C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: discord.py is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall discord.py` warn(message, DistributionWarning, stacklevel=0) C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: discord is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall discord` warn(message, DistributionWarning, stacklevel=0) C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\health_check.py:25: DistributionWarning: py-cord is installed which is incompatible with nextcord. Please remove this library by using `pip3 uninstall py-cord` warn(message, DistributionWarning, stacklevel=0) Traceback (most recent call last): File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 741, in _load_from_module_spec spec.loader.exec_module(lib) # type: ignore ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "<frozen importlib._bootstrap_external>", line 940, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "C:\Programieren\Neuer Ordner\cogs\music.py", line 3, in <module> from discord.commands import slash_command, Option, SlashCommandGroup, OptionChoice File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\__init__.py", line 26, in <module> from .context import * File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\commands\context.py", line 29, in <module> import discord.abc File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\abc.py", line 7, in <module> from nextcord.abc import (

#
ImportError: cannot import name '_Undefined' from 'nextcord.abc' (C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\abc.py)

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

Traceback (most recent call last):
  File "C:\Programieren\Neuer Ordner\main.py", line 24, in <module>
    bot.load_extension(f"cogs.{filename[:-3]}")
  File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 863, in load_extension
    self._load_from_module_spec(spec, name, extras=extras)
  File "C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\ext\commands\bot.py", line 744, in _load_from_module_spec
    raise errors.ExtensionFailed(key, e) from e
nextcord.ext.commands.errors.ExtensionFailed: Extension 'cogs.music' raised an error: ImportError: cannot import name '_Undefined' from 'nextcord.abc' (C:\Users\carol\AppData\Local\Programs\Python\Python311\Lib\site-packages\nextcord\abc.py)```
tawdry leaf
#

musst eine deinstallieren steht da 😄

urban glen
#

welche

tawdry leaf
#

was steht denn bis zeile 64

tawdry leaf
#

code bis zeile 64 senden

urban glen
tawdry leaf
#

denn deinstalliere nextcord

#

pip uninstall nextcord in terminal eingeben

#

ist slash cmd nh

urban glen
tawdry leaf
#

irgendwo oben sadge

#

sehe den nd zu weit oben

tawdry leaf
urban glen
# tawdry leaf kommt noch was danach?

das hier ist alles was im termianal ist ```C:\Programieren\Neuer Ordner>pip uninstall nextcord
WARNING: Skipping nextcord as it is not installed.

C:\Programieren\Neuer Ordner>```

tawdry leaf
#

mach mal pip freeze

#

und schaue ob da nextcord steht

urban glen
#
aiosignal==1.3.1
async-timeout==4.0.2
attrs==22.2.0
black==23.1.0
charset-normalizer==3.0.1
click==8.1.3
colorama==0.4.6
discord==2.1.0
discord.py==2.1.1
frozenlist==1.3.3
idna==3.4
llvmlite==0.38.0
locket @ file:///C:/ci/locket_1652904031364/work
lxml @ file:///C:/ci/lxml_1657527445690/work
lz4 @ file:///C:/ci/lz4_1619516674350/work
Markdown @ file:///C:/ci/markdown_1614364082838/work
MarkupSafe @ file:///C:/ci/markupsafe_1621528502553/work
matplotlib @ file:///C:/ci/matplotlib-suite_1660169687702/work
matplotlib-inline @ file:///C:/ci/matplotlib-inline_1661915841596/work
mccabe==0.6.1
menuinst @ file:///C:/Users/BUILDE~1/AppData/Local/Temp/abs_455sf5o0ct/croots/recipe/menuinst_1661805970842/work
mistune @ file:///C:/ci/mistune_1607359457024/work
mkl-fft==1.3.1
mkl-random @ file:///C:/ci/mkl_random_1626186184308/work
mkl-service==2.4.0
mock @ file:///tmp/build/80754af9/mock_1607622725907/work
mpmath==1.2.1
msgpack @ file:///C:/ci/msgpack-python_1652329316214/work
multidict==6.0.4
multipledispatch @ file:///C:/ci/multipledispatch_1607574329826/work
munkres==1.1.4
mypy-extensions==0.4.3
navigator-updater==0.3.0
nbclassic @ file:///opt/conda/conda-bld/nbclassic_1644943264176/work
nbclient @ file:///C:/ci/nbclient_1650290387259/work
nbconvert @ file:///C:/ci/nbconvert_1649741016669/work
nbformat @ file:///C:/b/abs_1dw90o2uqb/croots/recipe/nbformat_1663744957967/work
nest-asyncio @ file:///C:/ci/nest-asyncio_1649829929390/work
networkx @ file:///C:/ci/networkx_1657716998256/work
nltk @ file:///opt/conda/conda-bld/nltk_1645628263994/work
nose @ file:///opt/conda/conda-bld/nose_1642704612149/work
notebook @ file:///C:/Windows/TEMP/abs_79abr1_60s/croots/recipe/notebook_1659083661851/work
numba @ file:///C:/ci/numba_1650394399948/work
numexpr @ file:///C:/Windows/Temp/abs_e2036a32-9fe9-47f3-a04c-dbb1c232ba4b334exiur/croots/recipe/numexpr_1656940304835/work```
#

numpy @ file:///C:/ci/numpy_and_numpy_base_1653574844560/work
numpydoc @ file:///C:/Windows/TEMP/abs_30799058-86dd-4401-b621-d172137a4d87_ra3twm7/croots/recipe/numpydoc_1657529873713/work
olefile @ file:///Users/ktietz/demo/mc3/conda-bld/olefile_1629805411829/work
openpyxl==3.0.10
packaging==23.0
pandas @ file:///C:/b/abs_cdcgk91igc/croots/recipe/pandas_1663772960432/work
pandocfilters @ file:///opt/conda/conda-bld/pandocfilters_1643405455980/work
panel @ file:///C:/ci/panel_1657899702145/work
param @ file:///tmp/build/80754af9/param_1636647414893/work
paramiko @ file:///opt/conda/conda-bld/paramiko_1640109032755/work
parsel @ file:///C:/ci/parsel_1646740216444/work
parso @ file:///opt/conda/conda-bld/parso_1641458642106/work
partd @ file:///opt/conda/conda-bld/partd_1647245470509/work
pathlib @ file:///Users/ktietz/demo/mc3/conda-bld/pathlib_1629713961906/work
pathspec @ file:///C:/Windows/TEMP/abs_581d0u45mh/croots/recipe/pathspec_1659627132171/work
patsy==0.5.2
pep8==1.7.1
pexpect @ file:///tmp/build/80754af9/pexpect_1605563209008/work
pickleshare @ file:///tmp/build/80754af9/pickleshare_1606932040724/work
Pillow==8.4.0
pkginfo @ file:///tmp/build/80754af9/pkginfo_1643162084911/work
platformdirs @ file:///C:/b/abs_73cc5cz_1u/croots/recipe/platformdirs_1662711386458/work
plotly @ file:///C:/ci/plotly_1658142442431/work
pluggy @ file:///C:/ci/pluggy_1648024580010/work
poyo @ file:///tmp/build/80754af9/poyo_1617751526755/work
prometheus-client @ file:///C:/Windows/TEMP/abs_ab9nx8qb08/croots/recipe/prometheus_client_1659455104602/work
prompt-toolkit @ file:///tmp/build/80754af9/prompt-toolkit_1633440160888/work
Protego @ file:///tmp/build/80754af9/protego_1598657180827/work
psutil @ file:///C:/Windows/Temp/abs_b2c2fd7f-9fd5-4756-95ea-8aed74d0039flsd9qufz/croots/recipe/psutil_1656431277748/work
ptyprocess @ file:///tmp/build/80754af9/ptyprocess_1609355006118/work/dist/ptyprocess-0.7.0-py2.py3-none-any.whl```
#

py @ file:///opt/conda/conda-bld/py_1644396412707/work
pyasn1 @ file:///Users/ktietz/demo/mc3/conda-bld/pyasn1_1629708007385/work
pyasn1-modules==0.2.8
pycodestyle @ file:///tmp/build/80754af9/pycodestyle_1636635402688/work
pycosat==0.6.3
pycparser @ file:///tmp/build/80754af9/pycparser_1636541352034/work
pyct @ file:///C:/ci/pyct_1658488033428/work
pycurl==7.45.1
PyDispatcher==2.0.5
pydocstyle @ file:///tmp/build/80754af9/pydocstyle_1621600989141/work
pyerfa @ file:///C:/ci/pyerfa_1621560974055/work
pyflakes @ file:///tmp/build/80754af9/pyflakes_1636644436481/work
Pygments @ file:///opt/conda/conda-bld/pygments_1644249106324/work
PyHamcrest @ file:///tmp/build/80754af9/pyhamcrest_1615748656804/work
PyJWT @ file:///C:/ci/pyjwt_1657511236979/work
pylint @ file:///C:/Windows/TEMP/abs_518eqlbmoo/croots/recipe/pylint_1659110354241/work
pyls-spyder==0.4.0
PyNaCl==1.4.0
pyodbc @ file:///C:/Windows/Temp/abs_61e3jz3u05/croots/recipe/pyodbc_1659513801402/work
pyOpenSSL @ file:///opt/conda/conda-bld/pyopenssl_1643788558760/work
pyparsing @ file:///C:/Users/BUILDE~1/AppData/Local/Temp/abs_7f_7lba6rl/croots/recipe/pyparsing_1661452540662/work
pyrsistent @ file:///C:/ci/pyrsistent_1636093225342/work
PySocks @ file:///C:/ci/pysocks_1605307512533/work
pytest==7.1.2
python-dateutil @ file:///tmp/build/80754af9/python-dateutil_1626374649649/work
python-lsp-black @ file:///tmp/build/80754af9/python-lsp-black_1634232156041/work
python-lsp-jsonrpc==1.0.0
python-lsp-server @ file:///tmp/build/80754af9/python-lsp-server_1648176833691/work
python-slugify @ file:///tmp/build/80754af9/python-slugify_1620405669636/work
python-snappy @ file:///C:/ci/python-snappy_1610133405910/work
pytz @ file:///C:/Windows/TEMP/abs_90eacd4e-8eff-491e-b26e-f707eba2cbe1ujvbhqz1/croots/recipe/pytz_1654762631027/work
pyviz-comms @ file:///tmp/build/80754af9/pyviz_comms_1623747165329/work
PyWavelets @ file:///C:/ci/pywavelets_1648728084106/work
pywin32==302```
#

pywin32-ctypes @ file:///C:/ci/pywin32-ctypes_1607553594546/work
pywinpty @ file:///C:/ci_310/pywinpty_1644230983541/work/target/wheels/pywinpty-2.0.2-cp39-none-win_amd64.whl
PyYAML==6.0
pyzmq @ file:///C:/ci/pyzmq_1657615952984/work
QDarkStyle @ file:///tmp/build/80754af9/qdarkstyle_1617386714626/work
qstylizer @ file:///tmp/build/80754af9/qstylizer_1617713584600/work/dist/qstylizer-0.1.10-py2.py3-none-any.whl
QtAwesome @ file:///tmp/build/80754af9/qtawesome_1637160816833/work
qtconsole @ file:///opt/conda/conda-bld/qtconsole_1643819126524/work
QtPy @ file:///C:/ci/qtpy_1662015096047/work
queuelib==1.5.0
regex @ file:///C:/ci/regex_1658258307256/work
requests @ file:///C:/ci/requests_1657735342357/work
requests-file @ file:///Users/ktietz/demo/mc3/conda-bld/requests-file_1629455781986/work
rope @ file:///opt/conda/conda-bld/rope_1643788605236/work
Rtree @ file:///C:/ci/rtree_1618421015405/work
ruamel-yaml-conda @ file:///C:/ci/ruamel_yaml_1616016898638/work
s3transfer @ file:///C:/ci/s3transfer_1654512518418/work
scikit-image @ file:///C:/ci/scikit-image_1648214340990/work
scikit-learn @ file:///C:/ci/scikit-learn_1642617276183/work
scikit-learn-intelex==2021.20221004.171935
scipy==1.9.1
Scrapy @ file:///C:/Windows/TEMP/abs_f50e21j997/croots/recipe/scrapy_1659598707153/work
seaborn @ file:///tmp/build/80754af9/seaborn_1629307859561/work
Send2Trash @ file:///tmp/build/80754af9/send2trash_1632406701022/work
service-identity @ file:///Users/ktietz/demo/mc3/conda-bld/service_identity_1629460757137/work
sip==4.19.13
six @ file:///tmp/build/80754af9/six_1644875935023/work
smart-open @ file:///C:/ci/smart_open_1651235069716/work
sniffio @ file:///C:/ci/sniffio_1614030527509/work
snowballstemmer @ file:///tmp/build/80754af9/snowballstemmer_1637937080595/work
sortedcollections @ file:///tmp/build/80754af9/sortedcollections_1611172717284/work
sortedcontainers @ file:///tmp/build/80754af9/sortedcontainers_1623949099177/work```
#

soupsieve @ file:///tmp/build/80754af9/soupsieve_1636706018808/work
Sphinx @ file:///C:/ci/sphinx_1657617205740/work
sphinxcontrib-applehelp @ file:///home/ktietz/src/ci/sphinxcontrib-applehelp_1611920841464/work
sphinxcontrib-devhelp @ file:///home/ktietz/src/ci/sphinxcontrib-devhelp_1611920923094/work
sphinxcontrib-htmlhelp @ file:///tmp/build/80754af9/sphinxcontrib-htmlhelp_1623945626792/work
sphinxcontrib-jsmath @ file:///home/ktietz/src/ci/sphinxcontrib-jsmath_1611920942228/work
sphinxcontrib-qthelp @ file:///home/ktietz/src/ci/sphinxcontrib-qthelp_1611921055322/work
sphinxcontrib-serializinghtml @ file:///tmp/build/80754af9/sphinxcontrib-serializinghtml_1624451540180/work
spyder @ file:///C:/Windows/TEMP/abs_66k5aq_mkw/croots/recipe/spyder_1659599805372/work
spyder-kernels @ file:///C:/ci/spyder-kernels_1647011408404/work
SQLAlchemy @ file:///C:/Windows/Temp/abs_f8661157-660b-49bb-a790-69ab9f3b8f7c8a8s2psb/croots/recipe/sqlalchemy_1657867864564/work
statsmodels==0.13.2
sympy @ file:///C:/ci/sympy_1647853873858/work
tables==3.6.1
tabulate @ file:///C:/ci/tabulate_1657619055201/work
TBB==0.2
tblib @ file:///Users/ktietz/demo/mc3/conda-bld/tblib_1629402031467/work
tenacity @ file:///C:/Windows/TEMP/abs_980d07a6-8e21-4174-9c17-7296219678ads7dhdov_/croots/recipe/tenacity_1657899108023/work
terminado @ file:///C:/ci/terminado_1644322780199/work
testpath @ file:///C:/Windows/TEMP/abs_23c7fa33-cbb9-46dc-b7c5-590c38e2de3d4bmbngal/croots/recipe/testpath_1655908553202/work
text-unidecode @ file:///Users/ktietz/demo/mc3/conda-bld/text-unidecode_1629401354553/work
textdistance @ file:///tmp/build/80754af9/textdistance_1612461398012/work
threadpoolctl @ file:///Users/ktietz/demo/mc3/conda-bld/threadpoolctl_1629802263681/work
three-merge @ file:///tmp/build/80754af9/three-merge_1607553261110/work
tifffile @ file:///tmp/build/80754af9/tifffile_1627275862826/work
tinycss @ file:///tmp/build/80754af9/tinycss_1617713798712/work```
#

tldextract @ file:///opt/conda/conda-bld/tldextract_1646638314385/work
toml @ file:///tmp/build/80754af9/toml_1616166611790/work
tomli @ file:///C:/Windows/TEMP/abs_ac109f85-a7b3-4b4d-bcfd-52622eceddf0hy332ojo/croots/recipe/tomli_1657175513137/work
tomlkit @ file:///C:/Windows/TEMP/abs_3296qo9v6b/croots/recipe/tomlkit_1658946894808/work
toolz @ file:///tmp/build/80754af9/toolz_1636545406491/work
tornado @ file:///C:/ci/tornado_1606924294691/work
tqdm @ file:///C:/b/abs_0axbz66qik/croots/recipe/tqdm_1664392691071/work
traitlets @ file:///tmp/build/80754af9/traitlets_1636710298902/work
Twisted @ file:///C:/Windows/Temp/abs_ccblv2rzfa/croots/recipe/twisted_1659592764512/work
twisted-iocpsupport @ file:///C:/ci/twisted-iocpsupport_1646798932792/work
typing_extensions @ file:///C:/Windows/TEMP/abs_dd2d0moa85/croots/recipe/typing_extensions_1659638831135/work
ujson @ file:///C:/ci/ujson_1657525944442/work
Unidecode @ file:///tmp/build/80754af9/unidecode_1614712377438/work
urllib3 @ file:///C:/Windows/TEMP/abs_65ynz4fdmi/croots/recipe/urllib3_1659110473919/work
w3lib @ file:///Users/ktietz/demo/mc3/conda-bld/w3lib_1629359764703/work
watchdog @ file:///C:/ci/watchdog_1638367441841/work
wcwidth @ file:///Users/ktietz/demo/mc3/conda-bld/wcwidth_1629357192024/work
webencodings==0.5.1
websocket-client @ file:///C:/ci/websocket-client_1614804375980/work
Werkzeug @ file:///opt/conda/conda-bld/werkzeug_1645628268370/work
widgetsnbextension @ file:///C:/ci/widgetsnbextension_1644991377168/work
win-inet-pton @ file:///C:/ci/win_inet_pton_1605306162074/work
win-unicode-console==0.5
wincertstore==0.2
wrapt @ file:///C:/Windows/Temp/abs_7c3dd407-1390-477a-b542-fd15df6a24085_diwiza/croots/recipe/wrapt_1657814452175/work
xarray @ file:///opt/conda/conda-bld/xarray_1639166117697/work
xlrd @ file:///tmp/build/80754af9/xlrd_1608072521494/work
XlsxWriter @ file:///opt/conda/conda-bld/xlsxwriter_1649073856329/work```
#

xlwings @ file:///C:/b/abs_41rmpiyy58/croots/recipe/xlwings_1664932818417/work
yapf @ file:///tmp/build/80754af9/yapf_1615749224965/work
yarl==1.8.2
youtube-dl==2021.12.17
zict==2.1.0
zipp @ file:///C:/ci/zipp_1652273994994/work
zope.interface @ file:///C:/ci/zope.interface_1625036252485/work```
tawdry leaf
#

ich würde behaupten das du da bisschen viel schwachsinn installiert hast

urban glen
#

ka

tawdry leaf
#

geht auch nicht

urban glen
#

ne ist installiert

frail pewter
#

Guten Morgen ich könnte Hilfe gebrauchen.

from discord.ext import commands


class Button(commands.Cog):
    def __init__(self, bot):
        self.bot = bot

    @commands.Cog.listener()
    async def on_ready(self):
        self.channel_id = 1074986909522198620


        channel = self.bot.get_channel(self.channel_id)
        await channel.send("Hier gehts zur Rollenauswahl:", view=TutorialView())




def setup(bot):
    bot.add_cog(Button(bot))


class TutorialView(discord.ui.View):
    def __init__(self):
        super().__init__(timeout=None)

        ps4_emoji = discord.PartialEmoji(id=1079081578979926026, name=":ps4controller:", animated=False)
        button1 = discord.ui.Button(label="Ps4", style=discord.ButtonStyle.primary, emoji=ps4_emoji, custom_id="ps4")
        self.add_item(button1)

        ps5_emoji = discord.PartialEmoji(id=1079081659451834379, name=":ps5controller:", animated=False)
        button2 = discord.ui.Button(label="Ps5", style=discord.ButtonStyle.primary, emoji=ps5_emoji, custom_id="ps5")
        self.add_item(button2)

    @discord.ui.button(custom_id="ps4_emoji")
    async def button_callback1(self, button, interaction):
        role_id = 1074989549878521886
        role = interaction.guild.get_role(role_id)
        member = interaction.user
        await member.add_roles(role)
        await interaction.response.send_message("Du hast die PS4 Rolle bekommen!", ephemeral=True)

    @discord.ui.button(custom_id="ps5_emoji")
    async def button_callback2(self, button, interaction):
        role_id = 1074989886047797348
        role = interaction.guild.get_role(role_id)
        member = interaction.user
        await member.add_roles(role)
        await interaction.response.send_message("Du hast die PS5 Rolle bekommen!", ephemeral=True)``` 
seit gestern bekomme ich bei diesem Code folgende Fehlermeldung:

Ignoring exception in on_ready
Traceback (most recent call last):
  File "C:\Users\admin\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\client.py", line 377, in _run_event
    await coro(*args, **kwargs)
  File "C:\Users\admin\PycharmProjects\Discord_bot\cogs\rollenauswahl.py", line 15, in on_ready
    await channel.send("Hier gehts zur Rollenauswahl:", view=TutorialView())
  File "C:\Users\admin\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\abc.py", line 1606, in send
    data = await state.http.send_message(
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Users\admin\AppData\Local\Programs\Python\Python311\Lib\site-packages\discord\http.py", line 366, in request
    raise HTTPException(response, data)
discord.errors.HTTPException: 400 Bad Request (error code: 50035): Invalid Form Body
In components.0.components.0.label: This field is required
In components.0.components.1.label: This field is required
In components.0.components.2.emoji.id: Invalid emoji
In components.0.components.3.emoji.id: Invalid emoji
ich hoffe mir kann jemand helfen
mental hamlet
#

Das ist komplett falsch

#

Die ganze view Klasse

frail pewter
urban glen
torpid gorge
#

wie bekommt man den Text bei einem Embed field so blau wie beim /rank command?

torpid gorge
urban glen
# torpid gorge ah ok danke
Oder du machst es so xD
urban glen
torpid gorge
urban glen
torpid gorge
#

ok

urban glen
#

So könntest du machen

torpid gorge
#

ah ok

frail loom
#

Kann mir jemand sagen wie ich das beheben kann ?
Wollte meine db öffnen in pycharm aber dann kommt die meldung 😄

urban glen
#

Das kannst du nicht einfach so machen

frail loom
#

ich war eigendlich der meinung das ich da trotzdem was anderes gesehen habe als das, oder ich irre mich das kann auch sein

#

den browser habe ich, aber danke dir

urban glen
viscid lake
#

moin ich hab ein problem ich habe google.cloud.vision installiert aber wenn ich über from google.cloud import vision gehe steht da das ich es installieren muss
es steht auch in pip freeze drinnen

kennt wer eine lösung

urban glen
#

Versuch mal deine IDE zu restarten, kann sein das es danach übernommen wird, is bei mir auch so

viscid lake
#

ßip install google-cloud-vision

#

pip

scenic hazel
#

Soo da meine cogs jetzt funktionieren habe ich mich an slashcommands probiert. Die Frage ist wie synce ich die? Finde irgendwie kaum was richtiges Online?

import discord
import discord.ui
import datetime
from discord.ext import commands
from discord import app_commands


class Bank(commands.Cog):
    
    def __init__(self, client):
        self.client = client
    
    @commands.Cog.listener()
    async def on_ready(self):
        print("Bank cog wurde geladen")

    @app_commands.command(name="bank", description="Hiermit kannst du die Bankverbindung checken")
    async def bank(self, ctx):
        embed = discord.Embed(description="",
                              color=0x2adbc9,
                              timestamp=datetime.datetime.utcnow())
        
        embed.set_footer(text="Cosmany Hilfesystem",
                         icon_url=self.client.user.avatar)
        
        embed.add_field(name="Cosmany Bankverbindung",
                        value="Empfänger: Cosmany e.V.\nIBAN: DEXX XXXX XXXX XX\nVerwendungszweck: [Mitglieds-ID]",
                        inline=False)
        
        await ctx.reply(embed=embed, mention_author=False)
    
async def setup(client):
    await client.add_cog(Bank(client))
urban glen
scenic hazel
#

Er funktioniert zwar, sagt aber durchgehend das er 0 gesynced hat

visual swallow
#

Ich hätte ne Frage wie macht man solche Fun commands?

#

Wen man mehrere Optionen hat

#

Und eine Auswählt das dann ein Embed gesendet wird

urban glen
#
async def dice(self, ctx):
    num = random.randint(1, 6)
    await ctx.send(f"Ich habe {num} gewürfelt")

Bitteschön :D