sqlx-cli (if you need to change the database schema)
Set up environment variables
The bot reads the data it needs from environment variables.
To see which values have to be set, check out the provided .env.example file.
you can use export $(cat .env) to export the variables from a .env file in your current environment.
Extra information
Most environment variables are retrieved by right clicking, and copying the ID of the relevant channel, category, role.
You need to have developer mode turned on for that to be possible.
The bot uses a SQLite database, which does not have to be started externally.
The included sqlite-db file is not the actual database used in production, but just an empty database used for development.
To change and work with the database, use sqlx-cli to add migrations and generate a new, updated database file.
Hi, there was a raid in another dev server that happened due to a bot error, ending up making it look like this:
Friend sent me this explanation:
"This was an issue on Discords end not validating payloads properly in combination with bots that allow echoing any user input, both of which are not an issue in our server luckily.
more information in public announcement here:
Let me know if I need to answer more specific questions and I will, but this might be worth checking and making sure tru- i mean rob isn't affected by this.
Also, if possible, might be worth having at least one of the dev servers subscribe to the dev announcement channel from discord since they will post updates regarding bugs and issues. That's a side point though.
Enable a highlight feature where you get a dm with context of conversation where your keyword was in the conversation, example for mander by highlight bot in different server:
These are options that the bot has:
You set a list of highlights like so:
Also deletes your list and message after a few seconds so people don't abuse your highligts to annoy you.
Highlights remain even if messages are deleted, so if you are mentioned and the conversation is deleted, the whole conversation is still preserved.
Nothing necessary, just thought it would be a neat feature to add
Edit: realized that highlights don't activate while you are in chat, so for example, if someone is talking about mander and i sent a message in the same chat x seconds earlier, then i won't get a dm about it because I was there. Might be something to consider if you guys want to implement this
Channels and user mentions don't show in poll, as the description is put in the title. I believe descriptions were added into a field when we had trup.
The image shown in a fetch is removed if a user sends an attachment in the showcase channel that is not an image or a gif. I believe this was a problem with Trup as well.
Expected Behavior:
If I post a video in the showcase channel, my fetch image should not be removed.
!watch <user> [time]
would create a hidden channel where all actions of the given user are logged. This would make it easier for the mod-team to keep an eye on people, reducing moderation effort.
Watching would stop either after the time ran out, or after a mod runs !watch stop in the given channel.
The channel should stay existant until the mod runs !watch close.
Possible, major issue
Thanks to discord being rather weird, hidden channel names are still visible to the API as well as the audit-log. This would mean that anyone using a customized client could see the hidden channels, which would in many cases cause people to behave very differently and is also likely to cause regular discussions and complaints by community members.
Possible solutions
Channel names that don't show the name of the watched user. This would only partially fix the issue, as people would likely be able to guess that they are watched out of context.
Show the watch-logs externally, on a different server. This would work, but would be very unergonomic for the moderators, as well as be a hassle in general.
when you mistype a command, in many cases the bot prints the usage string. This response should get automatically removed after some time (~10 seconds).
This could also be done for "Success" style responses.
For this, there should probably be a new function SendAutoremove (or something like that) created in command.go, which resembles Reply, just that it automatically removes the message after a given amount of time.
Trup could autodetect message.txt files and as long as they're below a reasonable threshold (5000 characters? idk) write them out, split up into several messages.
Alternatively, this could be a command (!long or something, ran in the message that also sends the message.txt).
6gk:
very bad idea. sounds extremely spammy and abuse-prone.
a better solution could be to reupload to another service with a web interface (0x0.st, hastebin, pastebin, etc) & give a short preview, but even then it could be abused, at least it's not spammy though.
elkowar:
i mean, uploading to a separate service sounds like a good compromise, yea,...
if you set a line-limit (specifically lines + a char limit still), it couldn't be alllll that spammy
although I was informed that there are also betterdiscord plugins that show message.txt's, so maybe that's,..... a good enough workaround for me at least
If a user tries to fill out !setfetch manually, they should be prompted if they want to overwrite their current fields, or update them.
Detecting if a user is manually typing out !setfetch fields could be done by checking if the number of fields is less than the number of fields that the fetch.sh script outputs.
shows deleted & edited messages by user-id including content-of-message
Actual behavior:
doesn't work
doesn't work
works
doesn't work
[01:00] mlvzk | it stops tokenizing after it hits a number
[01:00] mlvzk | for some reason
[...]
[01:02] gk | Tokenizing? :blobthinkingglare:
[01:02] mlvzk | basically splitting words
[01:03] mlvzk | search engines have indexes in a format like ["basic", "split", "word"]
[01:04] gk | So basically snowflakes are broken in search?
[01:05] mlvzk | test 1231231231231 test101
[01:05] mlvzk | test Channel 458219829678047232 test101
[...]
[01:08] mlvzk | P 1:
| test1 test2 test3
|
|
| P 2
| test4 test5 test6
[01:09] mlvzk | discord finds this when i search "test3 test4" but doesn't when i search "test4 test3"
[01:09] gk | What about test3 test2
[...]
[01:26] mlvzk | Tokens: Edit, ghjcftvy, Channel 712091775086362676, Author 458219829678047232
[01:28] mlvzk | works: ghjcftvy channel 458219829678047232
| doesn't: ghjcftvy 458219829678047232
[01:28] mlvzk | yea im not implementing this for now
[01:28] mlvzk | it's buggy
Is your feature request related to a problem? Please describe.
The problem being that some emotes, even though they are newer are infinitely more popular. So when boost level drops, a really popular emote could be axed.
Proposed feature
Given how we already have our top guys working on #16 , this new feature could be implemented to re-arrange the emotes, which is an absolute pain to do manually.
Additional context
Well, some admins/mods might want to vouch for a few emotes they personally want. It's up to them to decide if they want to give possibilities of "immutability" to certain emotes. Those emotes would not be sorted based on their popularity.
Add a system to the bot where a project owner can “announce” updates to their project and it will dm or ping all of the members who have subscribed to that project.
This has been bugging me that robbb does not have this feature (not to be rude, though. What I mean by "Allow seeing who uses [insert distro/wm/etc.]" is you run (as an example !top DE/WM berry, it shows the amount of people using it, the percentage using it, and the people using it.
Helpers are allowed to mute. Currently, it's not clearly visible if the person is a moderator or a helper, which may be relevant when looking at a users cases afterwards. Thus, this should be tracked explicitly.
This will make it easier to decide what emotes to yeet when the time comes.
Reactions should be a separate counter (but still have a way to show combined usage), and the counter should go up by 1 for each message, so 9 people reacting to a single message with it will be the same as 1 person reacting to the message.
Is your feature request related to a problem? Please describe.
Currently Robbb's highlights don't provide context for the conversation which makes highlights harder to sort through. Example, if someone mention mander in passing, or while I am in the conversation, I don't really care for the highlight, but if someone is mentioning it in an interesting context, i care more.
Proposed feature
Context added to highlights, something like this:
This way I can see if this is important to me or not without having to actually jump to the highlight. This is even more useful when a word is highlighted rather than a name. For example, if I mention eww as in, eww that is disgusting and it triggers for people, they won't be as interested as if i were to actually talk about eww.
The warn and note commands should have a !note undo / !warn undo command to remove the latest warn / note.
lidl:
Instead of !note undo I think it would be better to do !note undo <note_id>. For this we would need !note to show notes together with their IDs, but the IDs are pretty long so we should just show the last 3 or 4 characters and use that in !note undo <note_id>
So that results in !top Editor don't have duplicate entries (1. nvim, 4. neovim should be joined into one)
Concept query:
WITH x AS (
SELECT
info ->>'Editor'AS value,
REPLACE(LOWER(info ->>'Editor'), 'neovim', 'nvim') AS normalized
FROM
sysinfo
WHERE
info ->>'Editor'!=''
),
y AS (
SELECT DISTINCTON (normalized)
value,
count(*) OVER (PARTITION BY normalized)
FROM x ORDER BY normalized,
count DESC
)
SELECT*FROM
y
ORDER BY
count DESCLIMIT5
value | count
--------+-------
Neovim | 96
vim | 55
nano | 24
Emacs | 10
micro | 8
(5 rows)
With fetches that where taken over from the migration, Memory: 0 is the value that users get when they didn't provide memory. This should still not be shown in the fetch.
Sucks when muted people leave and then are stuck that way.
gk:
there's got to be a timeout instead (or as well)
most of the time people are muted for a reason, if the mod leaves (or even got a request to mute when they're not in it) the culprit can just disconnect and come back and be unmuted instantly
Mods occasionally get singled-out for an action by a particular type of member, even if the other mods would have done the same thing, or even if there was a poll.
Proposed feature
The bot could delete the mod's !warn/!mute message and repost the reason/duration/etc.
if the mod pings, the user may still get a notification. (user error anyway)
it may still happen, albeit less often. As the mod (who might be) in chat can get blamed - even if it was another mod.
this may make "power abusers" less obvious, but I'd say that the other mods should be the ones handling this, and this shouldn't affect the mod-log channel.
Example:
mod [deleted by bot]: !warn 199492634438270977 bad person, basically Wu Zetian.
bot [not an embed so the ping works]: <@199492634438270977> has been warned for the 47th time: bad person, basically Wu Zetian.
(wording could of course be way better, but I'm not a linguist)
A possible alternative may be for the bot to DM warns/mutes, rather than saying publicly. I think this is a bad option, but at least worth saying.
This may sometimes cause less drama (onlookers not reading the full context and getting outraged because it sounds more minor than it is, bad reason, etc), but it's also less of a "hey other people, don't do this"
It's also rather frequent for people to disable DMs.