Giter VIP home page Giter VIP logo

nattadasu / ryuuryuusei Goto Github PK

View Code? Open in Web Editor NEW
7.0 2.0 1.0 2.5 MB

Find your profile and your favorite media titles with Ryuuzaki Ryuusei ๐Ÿš€

Home Page: https://nttds.my.id/ryuusei

License: GNU Affero General Public License v3.0

Python 99.94% Shell 0.06%
anilist anime bot discord discord-bot interactions-py jikan myanimelist nekomimi privacy-by-design simkl lastfm rawg discord-py-interactions discord-slash-commands shikimori slash-commands

ryuuryuusei's Introduction

Bot logo

Ryuuzaki Ryuusei


GitHub Bot Version Discord Shield

Codacy grade Codacy coverage
DeepSource DeepSource


Find your profile and your favorite media titles with Ryuuzaki Ryuusei. ๐Ÿš€

๐Ÿ“ƒ Table of Contents

๐Ÿง About

Are you a fan of anime, manga, games, TV shows, and movies? Do you want to find a Discord bot that can help you look up your profile from Discord without going anywhere and search for information about your favorite media titles from various sources? If yes, then you should check out Ryuuzaki Ryuusei! ๐Ÿ™Œ

Ryuuzaki Ryuusei is a rolling release Discord bot that uses interactions.py and Python to offer a variety of features and commands for Discord users. You can look up your profile from Discord, AniList, Shikimori, MyAnimeList, and Last.fm and customize your summary for each platform. You can also search for anime, manga, games, TV shows, and movies from platforms like MyAnimeList, AniList, SIMKL, Spotify, and more. You can also export your data in different formats and enjoy true randomness with some commands. ๐Ÿš€

The bot cares about your privacy by not storing any data on its server except for essential information. You can also delete your data anytime using the /unregister command. For more details, you can read the Privacy Policy. ๐Ÿ”’

The bot has many commands for different purposes, such as anime, manga, game, TV show, movie, music, and external link lookups. You can also access profile lookup commands, data control commands, settings commands (for both users and servers), randomization commands, and utility commands.

If you want to learn more about Ryuuzaki Ryuusei or invite it to your server, you can use the /about, /help, /invite, /ping, /privacy, and /support commands. You can also join the official support server or visit the GitHub repository to contribute to the development of the bot. ๐Ÿ’–

By inviting this bot to your server or using it, you agree to the Privacy Policy and Terms of Service.

Warning

This bot is a rolling release bot, which means that the bot may not be stable and may have bugs. If you find any bugs, please report it to GitHub Issues or on the support server.

๐ŸŒŸ Featured On

๐ŸŽˆ Usage

To use the bot, invite it to your server by pressing this button:

Shield

Next, go to the channel you want to use the bot in and type / to see the list of available commands.

All data invoked from /register will be stored in database.csv, user is able to delete their data by using /unregister command. Most commands can be used without /register command, although it may limit your experience using it.

If you have any questions, feel free to join the support server and ask there.

๐Ÿš€ Features

This also will be our to-do list for the bot. :3

  • Privacy-friendly: no data is stored on the bot's server, except for the essential data and caches. See Privacy Policy for more information.
  • Easily link optional supported platform by using /platform link command.
  • Delete your data from the bot's database at any time as you wish using /unregister command.
  • Beautiful embed with thumbnail and footer.
  • Simple yet powerful anime, manga, and game lookup.
    • Ability to select search result from multiple results rather than automatically selecting the first result. (I'm looking at you, Nadeko)
    • Accurate release date, adapted to your local timezone (based on MyAnimeList).
    • External links (MAL, AniList, AniDB, Kitsu, SIMKL, IMDb, TMDB, Trakt, and more).
    • A lot of information about the media compared to competitors: synopsis, genres and themes, rating with total votes, and more!
    • Know ID of the title you want to search? Use /media search command group instantly!
  • Shows your birthday directly from your MyAnimeList profile summary.
  • Customizable summaries for MyAnimeList, Last.fm, AniList, and Shikimori.
  • Export your data in JSON or Python dictionary format.
  • Experience the "true" randomness result on /anime random and /random nekomimi commands!1
  • Self-hosting on your phone? No problem! Bot has been tested on Termux on Android 11.
  • Does not support dynamic airing reminder. LiveChart + RSS bot is a good alternative.
  • Does not support updating your list to MyAnimeList. You can use White Cat instead.
  • Currently does not support character and cast lookup as it can be really complicated if you're using multiple platforms.

๐Ÿ“ฃ Available Commands

Emoji Legend Description
โŒš Planned and not available yet
๐Ÿ‘๏ธ Response is only visible to the user who invoked the command
๐Ÿซฆ Content may not be suitable for all age, may require NSFW channel
๐Ÿ‘ฎ Requires Administrator permission
๐Ÿ” Only available for server that hosted the bot

Commons Bot Commands

  • /about - Get information about the bot
  • ๐Ÿ‘ฎ๐Ÿ” /deepstats packages - Get deep statistics about the bot's PIP packages
  • /help - Get a list of all curretly available commands
  • ๐Ÿ‘๏ธ /invite - Get the bot's invite link
  • /ping - Check the bot latency
  • /privacy - Get information about the bot's privacy policy
  • /stats general - Get general statistics about the bot
  • /stats system - Get system statistics about the bot
  • /support - Support the bot by donating or contributing to the bot's development

Anime Commands

Utilize MyAnimeList via Jikan

  • ๐Ÿซฆ /anime info - Get information about an anime using direct MyAnimeList ID
  • ๐Ÿซฆ /anime random - Get a random anime from MyAnimeList, powered by AnimeApi
  • ๐Ÿซฆ /anime search - Search for an anime, using AniList's search API

Manga Commands

Utilize AniList

  • ๐Ÿซฆ /manga info - Get information about a manga using direct AniList ID
  • ๐Ÿซฆ /manga random - Get a random manga from AniList, powered by AniBrain
  • ๐Ÿซฆ /manga search - Search for a manga

Game Commands

Utilize RAWG

  • /games info - Get information about a game using direct RAWG ID
  • /games search - Search for a game

TV and Movie Commands

Utilize SIMKL for Metadata and TMDB for NSFW check

  • ๐Ÿซฆ /movie info - Get information about a movie using direct SIMKL ID
  • ๐Ÿซฆ /movie random - Get a random movie from SIMKL
  • ๐Ÿซฆ /movie search - Search for a movie
  • ๐Ÿซฆ /tv info - Get information about a TV show using direct SIMKL ID
  • ๐Ÿซฆ /tv random - Get a random TV show from SIMKL
  • ๐Ÿซฆ /tv search - Search for a TV show

Music Commands

Utilize Spotify

  • โŒš /music album info - Get information about an album using direct Spotify ID
  • โŒš /music album search - Search for an album
  • โŒš /music artist info - Get information about an artist using direct Spotify ID
  • โŒš /music artist search - Search for an artist
  • โŒš /music track info - Get information about a track using direct Spotify ID
  • โŒš /music track search - Search for a track

External Link Relation Command

Utilize nattadasu's AnimeAPI for video type, AniList for manga, and Song.link for music

  • โŒš /relations manga - Get external link relation for a manga, limited to AniList, MyAnimeList, and Shikimori
  • โŒš /relations music album - Get external link relation for an album
  • โŒš /relations music track - Get external link relation for a track
  • /relations shows - Get external link relation for an anime, TV, or movie

Platform Specific Commands

Show your profile from other platforms

AniList

  • /anilist profile - Get your AniList profile

Discord

  • /discord profile - Get your Discord profile

Last.fm

  • /lastfm profile - Get your Last.fm profile

MyAnimeList

  • /myanimelist profile - Get your MyAnimeList profile

Shikimori

  • /shikimori profile - Get your Shikimori profile

Data Control

  • ๐Ÿ‘๏ธ /export data - Export your data from the bot in JSON, CSV, YAML, and Python dictionary format
  • ๐Ÿ‘๏ธ /platform link - Link your Discord account to other platforms
  • ๐Ÿ‘๏ธ /platform unlink - Unlink your Discord account from other platforms
  • ๐Ÿ‘๏ธ /register - Register your MAL account to the bot
  • ๐Ÿ‘๏ธ /unregister - Unregister your MAL account and drops your settings from the bot
  • ๐Ÿ”๐Ÿ‘๏ธ /verify - Verify your MAL account to the server that host the bot (you may need to join the club first)
  • ๐Ÿ‘๏ธ /whoami - Show stored information and settings about you on the bot graphically and interactively

Settings Commands

User Settings

  • /usersettings autoembed - Toggle autoembed for the bot response from the user with supported platform URL.

Server Settings

  • ๐Ÿ‘ฎ /serversettings member register - Register member's MAL account to the bot, used when user can't invoke /register
  • ๐Ÿ‘ฎ /seversettings member verify - Verify memeber's MAL account after receiving verification code from either /serversettings member register or /register command, used when user can't invoke /register

Host/Admin Settings

These commands are only available for bot host staff in current configured server.

  • ๐Ÿ”๐Ÿ‘ฎ /hostsettings member verify - Verify member's MAL account to the server that hosts the bot, used when user can't invoke /verify

Randomization Commands

Collection of commands that returns (true) random result.

  • /random 8ball - Ask the magic 8 ball
  • /random number - Get a random number from Random.org
  • /random string - Get a random string from Random.org

Utility Commands

Collection of commands that are (might be) useful for everyday use.

  • /utilities avatar - Get user avatar, global or server
  • /utilities banner - Get user banner, global or UserBG
  • /utilities base64 - Encode or decode a string to or from Base64
  • /utilities color - Get color information
  • /utilities math - Evaluate a mathematical expression
  • /utilities qrcode - Generate a QR code from a string
  • /utilities site status - Check if the site is up or down
  • /utilities snowflake - Get a snowflake's information

Conversion Commands

Collection of commands that are used to convert something to another thing.

  • /converter currency - Convert currency from one unit to another
  • /converter length - Convert length from one unit to another
  • /converter mass - Convert mass from one unit to another
  • /converter temperature - Convert temperature from one unit to another
  • /converter time - Convert time from one unit to another
  • /converter volume - Convert volume from one unit to another

Images: Cat Ears (Nekomimi) Commands

Collection of commands that returns SFW images of characters in cat ears (nekomimi). Powered by nattadasu's nekomimiDB.

  • /nekomimi random any - Get a random image of character in cat ears (nekomimi) of whatever gender they are.
  • /nekomimi random boy - Get a random image of boy character in cat ears.
  • /nekomimi random girl - Get a random image of girl character in cat ears.

Japanese Commands

Collection of commands that are related to Japanese language.

  • /japanese transliterate - Transliterate a Japanese script to Romaji/Latin script

Dictionary Commands

Search a term from known dictionary!

Urban Dictionary

  • ๐ŸซฆโŒš /urban search - Search a term from Urban Dictionary
  • ๐ŸซฆโŒš /urban wotd - Get a word of the day from Urban Dictionary
  • ๐ŸซฆโŒš /urban random - Get a random word from Urban Dictionary

๐Ÿ Getting Started

Prerequisites

Before proceeding, ensure that you have installed dependencies installed on your system:

  • Git
  • Python (version 3.10 or higher)
  • For Linux user, you might want to install several additional packages:
    • gcc-c++, g++, or build-essential depending on your distro
    • python3-dev or python3-devel (or omit 3) depending on your distro

You can verify your Python version by running python --version or python3 --version or py -3 --version in your terminal/command prompt.

Note

In this guide, I will use python to refer to Python 3.10 or higher, and your system might use python3 or py -3 instead. So please adjust the command based on your system.

Also, you might need Discord account and Discord Bot Token.

Cloning the Repository

  1. Clone the ryuuRyuusei repository by executing the following command:

    git clone https://github.com/nattadasu/ryuuRyuusei
  2. Change your current working directory to the cloned repository:

    cd ryuuRyuusei

Setting up a Virtual Environment

  1. Create a virtual environment to isolate the bot's dependencies:

    python -m venv venv
  2. Activate the virtual environment based on your operating system and shell:

    • PowerShell

      • Windows
      & .\venv\Scripts\Activate.ps1
      • *nix
      & ./venv/bin/activate.ps1
    • Command Prompt/Batch:

      venv\Scripts\activate.bat
    • Bash (*nix):

      source ./venv/bin/activate
    • Fish (*nix)

      source ./venv/bin/activate.fish

    If you encounter any issues activating the virtual environment, make sure you have the appropriate permissions (root access might be required on Unix-like systems).

Installing Dependencies

Before running the bot, you need to install its dependencies. Execute the following command:

pip install aiohttp pyyaml pandas
  • If you are using Termux on Android, add MATHLIB="m" before the pip command, as there's known issue installing pandas dependencies:

    MATHLIB="m" pip install aiohttp langcodes pyyaml pandas

Running the Bot

  1. Run the initial setup script by executing the following command:

    python firstRun.py

    The following script will try to install the required dependencies, updating them, initialize database, download additional featured data, converting i18n files from YAML to JSON, and copy .env.example file as .env.

  2. If the .env file does not exist, follow this step, otherwise skip:

    • Copy the .env.example file to create a new .env file:

      cp .env.example .env
  3. Fill in the required credentials in the .env file.

  4. Finally, execute the following command to run the bot:

    python main.py

Congratulations! You have successfully set up and launched the Discord bot.

๐Ÿ› ๏ธ Development

You can contribute to the bot by forking the repository, making changes, and submitting a pull request.

See CONTRIBUTING.md for more information.

โ›๏ธ Built Using

Service/Package/Module Name FOSS? Scope Type Description
AniBrain - Random Database Get randomized result for manga, one-shot, and light novel, and show result from AniList
AniList - Anime, Censorship, Manga, Relation, Profile Database Mainly used for Manga commands, anime for searching
autopep8 MIT Utility Module Used for auto formatting
Codacy - Code Quality Code Quality Tool Used for checking code quality and linter
cutlet (Modified) MIT Language Module Used for transliterating Japanese text to Romaji
Deepsource - Code Quality Code Quality Tool Used for checking code quality, auto formatter, and linter
emoji MIT Language, Utility Module Used for converting emoji to Unicode
fake-useragent MIT Utility Module Used for generating random user agent
goQr - Utility API Used for generating QR code
interactions-py MIT Base Wrapper The backend of this bot!
Is It Down Right Now? - Utility API Used for checking if a website is down
Jikan MIT Anime, Profile, Verify 3rd Party MAL API Used for showing anime information, verify user, and show user's profile
Kitsu Apache-2.0 Anime Database Used for adding additional information to anime information, mainly background and poster
Last.fm - Profile Database Used for getting user's last.fm profile and scrobble summary
MyAnimeList - Anime Database Search and show anime information
nattadasu/animeApi AGPL-3.0 Random, Relation Relation Linking ID from a database to another database
nattadasu/nekomimiDb MIT Random Database Used for getting random nekomimi image
Odesli - Relation API Used for getting music link
plusminus MIT Utility Module Safely evaluate math expression
pykakasi GPL-3.0 Language Module Japanese tokenizer and script converter
PronounDB BSD-3-Clause Profile Database Used for getting user's pronouns
Random.org - Random Generator Used for generating (true) random number and string
Rawg - Game Database Used for searching and showing game information
Sentry - Bug Report Service Used for error tracking
Shikimori - Profile Database Used for searching and showing user profile information
SIMKL - Anime, Movie, Show, Relation, Random Database Used for searching and showing movie and show information, anime for additional information
The Color API Unknown License Utility API Used for getting color information
The Movie Database - Censorship Database Used for getting movie and show censorship information
Trakt - Relation Database Used for linking anime, movie, and show IMDb ID (provided by SIMKL and AniAPI) to Trakt ID
unidic MIT Language Module Used for getting Japanese word information
validators MIT Utility Module Used for validating strings

โœ๏ธ Authors

See also the list of contributors who participated in this project.

๐ŸŽ‰ Acknowledgements

  • Karasian, for creating the verification bot for The Newbie Club Discord server
  • Lacrima, YubiYuub, and Mental Illness, for helping me with the bot
  • White Cat, for the ability to link MAL account to Discord account and profile can be invoked anywhere.
  • And nearly all of the Discord bots with MAL functionalities, for inspiring me to create this bot... as most of bots didn't offer much information about the title compared to some (including this), smh.
  • And finally, a honorable mention to PowerShell, because it's literally my real first scripting language I learned, and because of it, I can create this bot in python... somehow, cough cough.

๐ŸŒŸ Stargazers

Star History Chart

โš–๏ธ License Compliance

FOSSA Status

Footnotes

  1. The random seed was generated using UUID4 and truncated to 32 bits (pandas couldn't able to get a sample using a seed above 32 bits unfortunately), and this seed generation happened everytime user invoked command. I can not guarantee the randomness as it is not the true random as in cryptographically secure random, but it's good enough that you should have hard time to get the same result twice in a row. โ†ฉ

ryuuryuusei's People

Contributors

deepsource-autofix[bot] avatar deepsource-io[bot] avatar dependabot[bot] avatar fossabot avatar imgbotapp avatar nattadasu avatar snyk-bot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

fossabot

ryuuryuusei's Issues

Add Application Context to Showcase Title from Supported Link

Description

Currently, Ryuuzaki Ryuusei allows users to showcase information about Anime, Manga, TV shows and movies manually. However, there is a missing feature related to the context menu when someone shares a supported site URL (such as MyAnimeList, AniList, Kitsu, Shikimori, Trakt, Anime-Planet, etc.). This feature request aims to address this issue by adding application context to showcase the title from the supported link.

Proposed Feature

The proposed feature involves enhancing the message context menu (right-clicking) functionality when a user shares a supported site URL. When the user invokes the command, Ryuuzaki Ryuusei bot will utilize regular expressions (Regex) to extract the ID from the URL (e.g., MAL ID: 1 for https://myanimelist.net/anime/1). Subsequently, the bot will submit the extracted ID to the appropriate location where the context is invoked (e.g., /anime, /manga, /shows, /movies).

Expected Benefits

By implementing this feature, users will be able to seamlessly retrieve and showcase the title of the anime, manga, TV show, or movie when sharing a supported site URL via the message context menu. This enhancement will streamline the user experience and provide convenient access to relevant information without the need for manual input.

Implementation Details

The implementation of this feature requires the following steps:

  1. Enhance the message context menu to capture supported site URLs.
  2. Utilize regular expressions (Regex) to extract the ID from the shared URL.
  3. Implement logic to determine the type of content (anime, manga, TV show, or movie) based on the supported site URL.
  4. Submit the extracted ID and content type to the appropriate location where the context is invoked (e.g., /anime, /manga, /shows, /movies).
  5. Retrieve the title information corresponding to the ID and display it in the showcase or relevant output.

It is essential to handle errors gracefully and provide appropriate feedback to users if the URL or ID extraction fails. Additionally, the implementation should be modular and adaptable to support additional supported sites in the future, ensuring the bot remains versatile and up-to-date.

Relocate /profile * to /* profile for improved command permission override and platform-related commands

Description

Currently, the ryuuRyuusei Discord Bot has subcommands under the /profile command that allow users to showcase their profiles from various platforms such as MyAnimeList, AniList, Shikimori, Last.fm, and Discord. To enhance command permission override in server settings and accommodate additional platform-related commands, it is proposed to relocate the /profile * command to /* profile. This change will provide more flexibility in managing command permissions and enable the addition of more platform-specific commands.

Proposed Changes

  1. Relocate the /profile * command to /* profile to improve command permission override in server settings.
  2. Update the necessary code and documentation to reflect the new command location.
  3. Modify the command handler to accommodate future platform-related commands.

Expected Benefits

  1. Improved command permission control: The relocation of the profile command will allow server administrators to have finer-grained control over who can access and use the command, enhancing server management and security.
  2. Compatibility with additional platform-related commands: By relocating the profile command and introducing a general structure for platform-specific commands, the bot can easily support new features and commands related to different platforms, providing a more versatile user experience.
  3. Enhanced user customization: With the command permission override improvements, server owners can define specific roles or users who can access and use the profile command, allowing for more personalized profiles and user experiences.

Implementation Details

  1. Update the bot's command handler to recognize the new command structure (/* profile) and redirect it to the appropriate code.
  2. Modify the existing documentation and README file to reflect the command relocation and provide instructions on configuring command permissions.
  3. Consider implementing additional platform-related commands (e.g., /discord server for previewing server information) following the same pattern as the relocated profile command.

Additional Considerations

  1. Conduct thorough testing to ensure the proper functioning of the relocated command and any new platform-related commands.
  2. Provide clear instructions and examples in the documentation on how to configure command permissions and utilize the new command structure.
  3. Communicate the command relocation and any new features to existing users, highlighting the benefits and improvements.

Known Bugs and Feature Suggestions

  • AniList not found may send both err json
  • Prefer to use context if user is 404 in AniList rather AniList err message
  • Add warning if user haven't link their AniList if registered or not
  • Occasionally KeyError on Jikan user data with key data (expected issue on caching) Kinda solved?
  • AniList manga may show "and 0 more" if tags and genres exactly 20
  • Add proper delimiter for counters (votes, chapters, volumes, episodes)
  • Add year if user consumed >12 months
  • Better phrase to tell user that they can lookup their profile without registering or linking
  • Add a way to ignore commands from serversettings command group if a group enabled in some channel, but want to keep several subcommand forbidden to use Unplanned
  • #188
  • Introduce cooldown
  • Fix Lastfm unable to showcase profile
  • #159

AniList Manga summary may not show "Read more on AniList" on Tagline + Followup Paragraph if Paragraphs more than 2

Description

As the title suggest, the bug appears when user showcasing a manga information from AniList from any method. Summary/description/synopsis with more than 2 paragraph will not show additional context to let user know if there's continuation if first paragraph is less than 150 characters (aka tagline) and less than 1000 chars on 2nd paragraphs

Possible Resolution

Create a logic to count total paragraph, if there's still more than 2 and 2nd paragraph is under 1000, force show the context.

Possible Occurences

There's possibility that this bug also occurs in /anime, /tv, and /movies. Thorough checking is required

Drop Discriminator from Username if Found

Description

In some actions that related to previewing or saving Discord's old user identification system (username with discriminator number), create a function to not show discriminator with its pound/hash tag if user had changed theirs to new user identification system (handle name).

This behavior will be a temporary measure before Discord ends discriminator globally.

Implementation Details

  1. Create a function in common module (modules/commons.py)
  2. Create a function to check and return username
  3. If discriminator value is either 0, "0", or None, returns only handle name.
  4. However, if user still has discriminator, renders completely the username with discriminator + pound tag.

[relations show]: SIMKL may unable to fetch IDs if platform is anime tracking sites

If User wanted to lookup relation from platforms neither Trakt, IMDb, TMDB, TVDB, and SIMKL, the relation data from SIMKL may not exist.

Possible culprit:

diff --git a/classes/simkl.py b/classes/simkl.py
index afe7477..7804c98 100644
--- a/classes/simkl.py
+++ b/classes/simkl.py
@@ -316,7 +316,7 @@ class Simkl:
             )
         params[f"{provider}"] = media_id
         async with self.session.get(
-            f"{self.base_url}/search/media_id", params=params
+            f"{self.base_url}/search/id", params=params
         ) as response:
             if response.status == 200:
                 data = await response.json()

Reference: https://simkl.docs.apiary.io/#reference/search/id-lookup/get-items-by-id

Rewrite Proposal No. 2: Repo Restructure, Semver, Plugins

Description

This issue will be a proposal on how Ryuusei "pleases" developers by better folder structures and ability to install additional plugins from dedicated repo

Changes

  1. Restructure repo to be "pythonic" as possible
  2. Follow Semver convention for each releases, starts at 1.0.0
  3. Add a way to download and manage additional plugins
  4. Proper typing and resolve linting issues >:o
  5. Use TOML based config system than using .env, so plugin can add additional credential input there
  6. Move nattadasu/ryuuRyuusei to ryuuRyuusei/ryuuRyuusei
  7. Change database system from TSV to SQL
  8. Move dataclasses to specific models/ folder
  9. On /myanimelist profile, prefer scraping MyAnimeList HTML than relying on Jikan to avoid unwanted err
  10. Create ๐Ÿ‘ tests ๐Ÿ‘ for ๐Ÿ‘ every ๐Ÿ‘ modules
  11. Create a template for issue and pull request
  12. Create a documentation website/folder on how to run bot, usage, and developing plugin for the bot
  13. Drop language support as it kinda overhaul maintainer capability
  14. Implement video embed if a service has attached URL to YouTube on title showcase

Add Confirmation if User wanted to remove, unlink, or changing language

Similar to how /register, /* search, and /serversettings register, warns user if they really wanted to delete their data, unlink a platform, or changing to (unfamiliar) language.

Implementation example:

async def unregister(ctx):
  # ...
  await ctx.send(embed=embed,
                 components=interactions.Button(label="Confirm",
                                                style=interactions.ButtonColor.DANGER,
                                                custom_id="user_confirm_action"))

@interactions.ComponentListener("user_confirm_action")
async def user_confirms(ctx):
  # rest of logic

Move MAL Showcase API from Jikan to MAL HTML

Due to continuous unknown/weird error from Jikan to lookup user profile like unable to fetch from uppercased username or straightforwardly unable to fetch the data at all, migrate the API from Jikan to MAL HTML parser in classes/html/myanimelist.py

However, the parser needs to be refined to be used without any issue

(PYL-E1123) Unexpected keyword argument in function call

Description

The function call has passed a keyword argument that doesn't correspond to one of the function's parameter names. This is an error.

Occurrences

There is 1 occurrence are 2 occurrences (on a freaking same function) of this issue in the repository.

See all occurrences on DeepSource โ†’ app.deepsource.com/gh/nattadasu/ryuuRyuusei/issue/PYL-E1123/occurrences/

edited by @nattadasu himself, expect passive aggressive he wrote here as he a bit dumbass

Replace themes.moe to animethemes.moe

Based on my observation, we can create a custom slug by:

  1. Take an anime title from MyAnimeList
  2. Remove any characters outside [\w\- ]+ in Regex
  3. Use slugify.slugify to safely convert the link to slug
  4. Modify the slug to use underscore (_) than a dash
  5. Link to https://animethemes.moe/anime/:slug

Escape Characters on Last.fm Command

If someone listened to an artist/track that contains left bracket ), hyperlink would break due to that.

Possible solutions:

  1. Only escape left bracket to percent entity.
  2. Manually split the links by slash / and escape all characters that might break markdown.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.