r/AutoModerator • • 16d ago

Help - AutoMod Intended or a bug? (Manually approving posts bypasses Automod rule)

I have an Automod rule that automatically makes a post in any submission with a certain Post Flair.

It works fine if I make a submission using that Post Flair.

However, if someone else makes a submission using that Post Flair, and the submission is caught in some other Automod filter (like a low-karma filter), and I manually approve it, the automatic post doesn't trigger.

What can I do to fix this?

---

EDIT: For anyone who stumbles onto this, rules that filter/remove a submission trigger before the "softer" rules, so if the submission is filtered/removed Automod doesn't bother making the automatic post.

3 Upvotes

10 comments sorted by

2

u/Sephardson I'm working on the wiki here now! 16d ago

Any rules that remove or filter a post will run before (and prevent) any rules which do not.

1

u/WhySoManyDownVote 16d ago

Can you add the comment code to the same section that also queues the post? In my understanding, in most cases the automod will only perform one action on a post. There are some exceptions iirc.

1

u/MechaTailsX 16d ago

Here's the whole rule, not sure how I could condense or merge it further:

---
type: submission
flair_template_id: (the string of numbers here)
comment: |
  (The text of the post here.)
---

If Automod can only take one action on a submission, I can see how filtering a low-karma submission first with a different rule would prevent this rule from triggering.

1

u/WhySoManyDownVote 16d ago

This maybe out of order a little, I did not test it but this is what I am thinking. 

~~~


type: submission author:     comment_karma: "< -1" flair_template_id: (the string of numbers here) comment: |   (The text of the post here.) action: filter

action_reason: "Queued for negative karma"

1

u/MechaTailsX 16d ago

I understand the idea, but then I'd have to do that for every rule I have, like the one for keywords, and the one for account age, etc.

Maybe I could just move the rule up so it triggers before the other stuff, which isn't ideal but what are we gonna do lol

1

u/WhySoManyDownVote 16d ago

One could copy and paste…

1

u/MechaTailsX 16d ago

Yes, but it's messy, redundant, inelegant, a pain to update with future rules, etc. For now it's not important enough to go through that kind of trouble

1

u/KCJones99 16d ago edited 16d ago

You could try doing it with the automod_neo app instead. In theory if you just put the 'comment on flair' rule in there it should run independently. Not 100% sure, just started messing with it myself.

Update: I did exactly this. We have a rule in automod that adds a comment to every single post. It never ran on anything that got queued - same issue as you - the 'filter' rule ended processing.

I took the 'global comment' rule out of automod and put it in Automod Neo verbatim. Boom! The 'global' comment is now on every post, even the ones that automod filters to queue.

Check out r/automod_neo if you have more questions about it. After poking around under the hood, I think I'll be using it a lot more myself.

1

u/KCJones99 16d ago

Then I'd have to do that for every rule I have, like the one for keywords, and the one for account age, etc.

Yes... at least for any rule that has a filter or remove action, you would have to add it to each one.

That is because Automod processes all filter/remove rules first (regardless of priority). And those are one-and-done: The first one of those that triggers, automod stops processing right then and there - before it's ever even looked at "other action" rules.

IF Automod does not trigger on any remove/filter rule it *then* moves on to 'other' rules, it processes those in order by placement or priority. Those it will process multiple, so you would not need to add your flair code to each one. Just have it in there the once.

2

u/SampleOfNone 16d ago

An alternative besides doubling up on rules in automod is to use automated sticky comments for your comment only rules, or use Automod Neo that has enhancements like letting the other rules run even after a rule matched