Giter Site home page Giter Site logo

marahin / letter-bot Goto Github PK

View Code? Open in Web Editor NEW
8.0 2.0 7.0 350 KB

Letter is a Discord bot for reserving respawns in Tibia.

Home Page: https://tibialoot.com

License: MIT License

Dockerfile 0.35% Makefile 1.20% Go 98.31% Nix 0.14%
booking bot discord respawn tibia

letter-bot's People

Contributors

dependabot[bot] avatar marahin avatar patryk-fuhrman avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

letter-bot's Issues

Make BotPort part of Application services

In the past we did not do many Discord operations as part of an application logic. Features have been growing (DM notifications, DM summaries) and it's time to encapsulate Discord operations as part of Application services, instead of passing Bot instance to some of the hooks handled by the event handler.

Better error handling for 50007 (user blocked DM)

Users who have DMs blocked may receive DC error code 50007 (couldn't send DM to a user).

Per user report:

could not send letter message: HTTP 403 Forbidden, {"message": "Cannot send messages to this user", "code": 50007}

We should instead notify the user the action failed, and provide some basic instructions (unblocking DMs, unblocking the bot).

Conflicting reservations should be 'shortened' instead of removed

Imagine the following scenario:

  • reservation exists for 19:00-22:00
  • a new reservation request came, for 21:30-23:30 with overbook set to true

Current behavior

The conflicting reservation (1st) is removed entirely, and a new reservation from 21:30 to 23:30 is created.

Expected behavior

The conflicting reservation (1st) is shortened to 19:00 - 21:29, and the 2nd one is created 21:30-23:30

overbooking only after after 10 min

Hello, please change "overbook". It should be possible to overbook only if there is more than 10mins after begin of reservation. Example: I booked a spot 10:00-12:00, and it should be possible to overbook only after 10:10.
image

Sanitize hours input during Booking

obraz
obraz

We could sanitize those inputs, so that:

  • "19.05" becomes "19:05" (sub "." to ":")
  • "24:00" is translated to "00:00" before proceeding with BookRequest

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.