Avoid spamming #firemc #6
No reviewers
Labels
No labels
Kind/Breaking
Kind/Bug
Kind/Documentation
Kind/Enhancement
Kind/Feature
Kind/Security
Kind/Testing
Priority
Critical
Priority
High
Priority
Low
Priority
Medium
Priority
Zero
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference: Firepup650/FireBot#6
Loading…
Reference in a new issue
No description provided.
Delete branch "9pfs/FireBot:dont-spam-firemc"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
idk?
d3a824dc24
toce5c979e8d
You're gonna have to force update again @9pfs, I had to amend my last commit.
I don't want an entire check in the primary bot code for this, if you're absolutely set on this, please add a
QUIT
handler tohandlers.py
, and then have it parse theQUIT
line there. Then check the user (and host if you want to) whoQUIT
, and then I'll throw in a per-server check on it so we don't run this on random servers for no reason.ab865d3dbb
to9c5a305a02
please remove this now
That change was reverted by
ab865d3dbb
.lmao i must have been in the middle of a review when you reverted
Uh... the timer should be removed by this PR too, right?
@ -175,0 +175,4 @@
def QUIT(bot: bare.bot, msg: str) -> tuple[None, None]:
if bot.server == "replirc":
if msg.split("!", 1)[0][1:] == "FireMCBot":
bot.send("TOPIC #firemc :FireMC Relay channel (offline)\n")
Last line of the function MUST be
return None, None
, it'll crash otherwise.Fixing
Probably, make sure to remove it from the config as well. (also please bump the bot version up one)
Reverting that specific commit is bad, there were other changes bundled in that commit that are critical.
@ -271,3 +271,3 @@
for thread in self.threads:
tdict[thread] = timers.data[thread]
if tdict[thread]["passInstance"]:
if thread in ["radio"]:
Critical change, needs to be un-reverted
@ -118,4 +117,3 @@
data: dict[str, dict[str, Any]] = {
"radio": {"noWrap": True, "func": radio, "passInstance": True},
related to my other commit, this needs to use the new
passInstance
param.@ -127,2 +120,2 @@
"ignoreErrors": True,
},
"radio": {"noWrap": True, "func": radio, "args": []},
"mc-down": {"noWrap": False, "func": mcDown, "args": [], "interval": 60, "ignoreErrors": True}
Reverting that commit didn't even remove the timer, lol
Looking for other commits to revert then
Just revert the revert, I'll delete the stuff that needs removal myself if you want.
@ -271,3 +271,3 @@
for thread in self.threads:
tdict[thread] = timers.data[thread]
if tdict[thread]["passInstance"]:
if tdict[thread]["passInstance"]:
This needs to be indented another layer
@ -126,3 +116,1 @@
"interval": 60,
"ignoreErrors": True,
},
"radio": {"noWrap": True, "func": radio, "args": []}
radio
needs to use"passInstance": True
, not"args": []
@ -271,3 +271,3 @@
for thread in self.threads:
tdict[thread] = timers.data[thread]
if tdict[thread]["passInstance"]:
if tdict[thread]["passInstance"]:
We CANNOT use a tab here, this will crash the bot. It absolutely must be 4 spaces.
Uh, what? I thought that WAS 4 spaces!
wtf does it mean no key.
I'm honestly shocked that you just approved this mess.
do I have to give forejo a key or something?
Maybe I'd have to add a key? idk, worst case scenario you could always merge, pull,
git commit --amend --no-edit -S
, and force pushIt literally won't let me merge it as-is, I'd have to override protection rules to merge this.
I'll try to set up a key then, ig
Never mind, idk how
https://forgejo.org/docs/v1.19/admin/config-cheat-sheet/#repository---signing-repositorysigning
I think?
I just saw that, it makes absolutely no sense. Could you enable manual merge detection + do
git remote add h ssh://h@git.h.hackclub.app:3322/9pfs/FireBot.git;git fetch --all;git switch master;git merge h/dont-spam-firemc;git commit --amend --no-edit -S
to merge?I think what that means is that you need a
repository.signing
MERGES
key with something likeapproved
as the value inapp.ini
.https://codeberg.org/forgejo/forgejo/src/branch/forgejo/custom/conf/app.example.ini#L1122-L1162
...
Oh!!! I think I need to create a forgejo signing key + abuse BindPaths to make it get used or something.
There's an option at the top of the signing block to use a default key, why not just enable that?
I merged this manually, for now. Closing PR since forejo is being silly.
Pull request closed