Giter Site home page Giter Site logo

diru's Introduction

Hi there ๐Ÿ‘‹

I'm Ludoviko, also known as Ludo or Luฤ‰jo, I'm an electonics engineer from Europe that codes in my free time. My pronouns are they/them/theirs but any will do!

Current projects

Honestly, there's so many projects that I'm working on.

Note: Some of my newer projects are on my personal Git server, they will arrive here when there is a release ready.

How to reach me

The best way is probably by e-post or Matrix but here are my full socials:

Mastodon Follow
Chat on Matrix
Website
Blog
Send an e-post

  • Discord - @ludoviko (avoid)
  • Session:
05f7525a7ff9448f1e83dc32b2634e9fbaccaa2ce41eea324183401136adf4e755

Stats

Ludo's GitHub stats Top Langs

Donating

You can donate to any of my projects (or me in general) through:

You can also donate through Crypto:

  • BTC:
bc1qt6x9ese0xlykhsz4m06kfyheya8kad9wuze3e6
  • ETH (also supports ERC20):
0x350280ba7D9d59cE4F8618DA187A5EE739E55bE2
  • Polygon (MATIC and other ERC20)
0x350280ba7D9d59cE4F8618DA187A5EE739E55bE2
  • XTZ
tz1TGmYFvYJrCFojiZVNfnLhF9mS1vzphUYN
  • LTC
ltc1qt0yanfag307cpvuzfpujpvkrtlqh8gcuqahv5h

diru's People

Stargazers

 avatar

Watchers

 avatar

diru's Issues

Improve configuration

With the addition of Google Translate, the configuration of the bot should be updated.

  • Switch config handler to Viper (if possible) (#16)
  • Allow for only Google Translate or DeepL to be added (#17)
  • Allow for per-server configuration as to whether gtr or dpl is used by default (#18)
  • Allow for per-server configuration as to what language is used by default (#18)
  • Allow for predetermined defaults as to whether gtr or dpl is used by default

[Node] Google Translate

Add translations via Google into Diru.Node

Translations via Google are needed as part of feature parity between Diru.Go and Diru.Node.

Related Issues

#29

Crash on send to Top.gg if API is busy

Crash on send to Top.gg if API is busy, I would also expect this to happen if a rate limit is applied.

Environment: Docker
Bot version: 1.0.3-1.0.4 (all?)
Self-hosted: โŒ 
Logs Post "https://top.gg/api/bots/{id}/stats": context deadline exceeded (Client.Timeout exceeded while awaiting headers) panic: runtime error: invalid memory address or nil pointer dereference [signal SIGSEGV: segmentation violation code=0x1 addr=0x40 pc=0x6b121c] goroutine 55 [running]: github.com/lucxjo/diru/utils.SendTopggData({0xc000150140, 0x9b}, {0xc000018168, 0x12}, 0x1, {0xc000116300, 0x3b}) /app/utils/topgg.go:31 +0x3dc main.main.func1() /app/diru.go:33 +0x171 created by github.com/andersfylling/disgord.(*rdyCtrl).OnRemove /go/pkg/mod/github.com/andersfylling/[email protected]/reactor.go:403 +0x8e

Crashing when no phrase is passed

When no phrase is passed and the message isn't a reply, the bot crashes.

Environment: Docker
Bot version: 1.0.3
Self-hosted: โŒ 
Logs panic: runtime error: index out of range [2] with length 2 goroutine 2989 [running]: github.com/lucxjo/diru/cmd.Dpl(0xc00000c3c0, {0x7de4c0, 0xc00010cc60}, 0x1) /app/cmd/dpl.go:14 +0x305 github.com/lucxjo/diru/cmd.Commands(0xc00000c3c0, {0x7de4c0, 0xc00010cc60}, 0xc00001c200, {{0xc000116300, 0x3b}, {0xc00006e4b0, 0x24}, {{0xc000150140, 0x9b}, ...}}) /app/cmd/commands.go:19 +0xa7 main.main.func2({0x7de4c0, 0xc00010cc60}, 0x20) /app/diru.go:39 +0x65 github.com/andersfylling/disgord.(*dispatcher).trigger(0xc0004ae0c0, {0x6f6080, 0xc0004ac050}, {0x71c1c0, 0xc0004046a0}) /go/pkg/mod/github.com/andersfylling/[email protected]/reactor_gen.go:621 +0x477 github.com/andersfylling/disgord.(*dispatcher).dispatch(0xc0000543c0, {0xc00001a970, 0xe}, {0x71c1c0, 0xc0004046a0}) /go/pkg/mod/github.com/andersfylling/[email protected]/reactor.go:148 +0x5ae created by github.com/andersfylling/disgord.(*Client).demultiplexer

Implement code testing

The project has now gotten to the point where it ideally needs code testing to ensure that nothing that is already implemented breaks with future updates where possible.

[Node] DeepL Translations

Add translations via DeepL into Diru.Node

Translations via DeepL are needed as part of feature parity between Diru.Go and Diru.Node.

Related issues

#29

[Node] Guild preferences

Add guild preferences into Diru.Node

Guild preferences are needed as part of feature parity between Diru.Go and Diru.Node.

Related issues

#29

Convert project to Rust

Superseeds #29

Motivation

Diru was originally written as a bot for a server that I'm an admin in, I wrote it in Go to be as small and light on resources as possible. It was also kind of a "let's see what I can do with Go" project. While writing it, I have found how hard to maneuver Go can be and that the Discord library that I'm using (Disgord) isn't really ready for production. With this in mind, to go further with this project (and for it's survival), I believe that the bot needs to be ported to Rust. The original plan was to convert to TypeScript instead but I end up fighting with the compiler too much, which is why the switch to Rust instead.

Future Plans

Once the Rust version has parity with the Go version, more improvements will happen. @Diru commands will be depreciated on release in favour of application commands instead.

Tasks to complete:

  • PARITY
    • Translation through DeepL
    • Translation through Google Translate
    • Guild preferences
  • IMPROVEMENTS
    • Context menu translations

Crashing on reply without function

The bot is crashing when someone uses it and mentions the bot without the dpl* or gtr* function. This only happens when replying to a message.

Logs

goroutine 8926 [running]:
github.com/lucxjo/diru/cmd.Commands(0xc00000c1e0, {0x10796a0, 0xc00012f7a0}, 0xc00055a0a0, 0xc0000766c0, 0xc00012f7a0)
/app/cmd/commands.go:39 +0x2112
main.main.func3({0x10796a0, 0xc00012f7a0}, 0x20)
/app/diru.go:88 +0x46
github.com/andersfylling/disgord.(*dispatcher).trigger(0xc0004676e0, {0xd20580, 0xc0005784a0}, {0xd9ada0, 0xc000400050})
/go/pkg/mod/github.com/andersfylling/[email protected]/reactor_gen.go:621 +0x477
github.com/andersfylling/disgord.(*dispatcher).dispatch(0xc0000353c0, {0xc0005122f0, 0xe}, {0xd9ada0, 0xc000400050})
/go/pkg/mod/github.com/andersfylling/[email protected]/reactor.go:148 +0x5ae
created by github.com/andersfylling/disgord.(*Client).demultiplexer
/go/pkg/mod/github.com/andersfylling/[email protected]/reactor.go:70 +0x2cf

Convert project to Discord.TS

Motivation

Diru was originally written as a bot for a server that I'm an admin in, I wrote it in Go to be as small and light on resources as possible. It was also kind of a "let's see what I can do with Go" project. While writing it, I have found how hard to manoeuvre Go can be and that the Discord library that I'm using (Disgord) isn't really ready for production. With this in mind, to go further with this project (and for it's survival), I believe that the bot needs to be ported to Node and TypeScript. The current version (at the point of writing this), will be known as Diru.Go, and the newer one will be known as Diru.Node when clarity is needed.

Future plans

Once Diru.Node has full feature parity with Discord.Go, we can get started with the improvements. I want to ensure that the reliance on text commands goes away in favour of application commands (a.k.a slash commands) as well as context menus (where possible).

@Diru commands will be depreciated on 2023-01-28 at 13:00 (UTC)

Tasks to complete:

  • PARITY
    • Translation through DeepL (#30)
    • Translation through Google Translate (#33)
    • Guild preferences (#34)
    • Web landing page (for status page) (#35)
  • IMPROVEMENTS
    • Web API to ensure obfuscation of user information to 3rd party services

Per server configuration

Servers should be able to configure whether they default to English or a different language, or Google Translate or DeepL

Web landing page (for status page)

Add web landing page.

A web landing page is needed as part of feature parity between Diru.Go and Diru.Node. Within this, the web landing page should be improved to also show better documentation for the bot.

Related issues

#29

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.