Abstract: Many gauge theories in four dimensions are based on PDEs that involve a gauge connection coupled to other fields. The latter are usually a source of a major headache since they lead to non-compactness of the moduli spaces. Today we will discuss two aspects of this major problem and two ways of dealing with it. One will help us understand how to perform cutting and gluing in Vafa-Witten theory, i.e. to what extent this theory is a (decorated) TQFT or, rather, how far it actually is from a decorated TQFT. This question is important for topological applications, such as behavior of the Vafa-Witten invariants under Gluck twist, log-transforms, and other surgery operations. The second part of the talk and another look at non-compactness of moduli spaces will lead us to a new “version” of the Vafa-Witten theory that is closer to vertex algebras VOA[M_4] and related developments.