Bram28 did the question justice and deserves the check mark but I'm going to answer the question from a more "creative" perspective that I hope everyone enjoys.
From a logic perspective, I see a "fallacy" in an argument as any kind of "false inference"; in other words, a conclusion $B$ from a collection of statements $\Gamma$ that isn't provable in classic logic. In other words,
\begin{align*}
\Gamma \\
\therefore B,
\end{align*}
when $\Gamma \nvdash B$.
If $\Gamma:=\{A_1, \ldots, A_n\}$ is finite, this is equivalent, using the deduction theorem and completeness theorem, to $(A_1 \land \ldots \land A_n) \rightarrow B$ not being a tautology, meaning that $\not \models (A_1 \land \ldots \land A_n) \rightarrow B$--i.e. there exists a truth table $T$ such that $(A_1 \land \ldots \land A_n) \rightarrow B$ is false.
So a logical fallacy can be equivalently be defined any pair $(\Gamma, B)$, with $\Gamma$ finite, such that $(A_1 \land \ldots \land A_n) \rightarrow B$ is not a tautology.
Turns out that such a collection is "decideable" (in order words, we can write a computer program that classifies whether or not $(\Gamma, B)$ is a logical fallacy), since the tautologies in propositional logic (the complement of what I'm calling a "logical fallacy") are decideable.
However, with most forms of predicate logic, and likely a similar issue arises with Syllogistic logic since that logic uses quantifiers as well, we are not so fortunate and the "logical fallacies" in those end up being "undecideable". But we can formalize "logical fallacies" using the same definition. We're just not able to compute them all.
I have a little more to write about how we can also look at logical fallacies from the perspective of inferring one connective from another connective (a generalized version of what Bram28 was doing), but will do so in an edit of this post. Thanks for reading and I appreciate feedback!