WE ARE REWRITING TS š„
First - implemented protection through send permissions. This is vastly more effective than kicking them (race condition) and also looks cooler! Downside: itās a little more to manage, because thereās no easy way to just say āgib permissionā and āno gib permissionā - you have to set the entirety of the permissions (which are stored in such a weird way lol). Thereās so many new things unlocked here, so Iāll detail those later as well.
After a bit of work on the send permissions thing, I made a whitelist. Simple. Whitelist a user from IDV blocks. Or perhaps whitelist a bunch of people. Simple.
There was one big problem though. The means by which I accomplished this essentially meant scattering logic in a ton of different places. Iād have logic in leave/join handlers, and honestly, the entire codebase was a mess.
I took the decision to instead rework the entire codebase, with a new strategy. Iād keep all user info stored in the SQLite database, and all commands would interface with that database. Then, that database would be synced with Slack. This way, the logic ends up being separated out.
This was enough of a shift that warranted the creation of a new repo. New deployment issues, new failures, a bunch of nonsense with token rotation and app creation, and there we go!
IDV protection? Hell yeah! #idv-only only lets IDVed members join.
Whitelists are now a thing, and /blam whitelist channel keeps all members in the channel allowed for the future.
/blam help shows all available commands.
Lots of perf improvements
/idv test basically runs through the users and finds out how many of them would be affected by a /blam idv - it does need performance improvements soon :pf:
Thatās about it for now! Lots of edge cases are hanging around that need to be patched up.
Log in to leave a comment
Whoah, first devlog! Lots of progress so far:
But then, I ran into a problem - occasionally, XOXP tokens donāt work to kick. And users added to channels donāt seem to be able to kick immediately. And even more worryingly, even with channel manager given to the kicking user, it fails. I believe itās because the XOXP has to be refreshed (manually?!) each time itās added.
Yeah, thatās not going to work. I made a little hack that uses XOXC and XOXD tokens instead to kick, and it works!
I skipped over a lot of detail in how many times I failed, but yeah thatās about it!
Also - Iām really kind of happy with the _env implementation I landed on. I wrap all my getenv calls in a custom function which validates the vars.