The approach above is common in applications, due to its convenience, but rare in mathematics, due to its sloppiness. Specifically, $f$ is poorly defined: Is it a function $\mathbb{RxR} \to \mathbb{R}$? If so, what does it mean to constrain the second parameter as a function of the first?
What we really want is: Given $f(x,y), a(x), b(x)$, define $g(x): \mathbb{R} \to \mathbb{R}, x \mapsto f(a(x), b(x))$.
This proper notation highlights that, in the sloppy original notation, ${\partial f}/{\partial q}$ could have two meanings (!), and you had to figure it out based on context: either the slope of $f$ if only the first param change, and we could somehow hold the second param constant; or the slope of $f$ if the first param changes and the second param changes accordingly. Our new notation fixes that, because $f$ is an arity-2 function, and g is an arity-1 function, and both can take any args in their domain (as a function should!).
Continuing the notational upgrade, we use Spivak's $D$ operator, such that if $f: \mathbb{R^m} \to \mathbb{R^n}$, $Df$ is also a function from $\mathbb{R^m} \to \mathbb{R^n}$. (In this notation, partial derivatives are simply selecting a single entry from the derivative, and the gradient, Jacobian, and ordinary derivative are all the same thing, with the name changed if $n$ or $m$ equal 1.) So we can write a single function $c: x \mapsto (a(x), b(x))$, and use the multivariable chain rule $Dg(x) = D(f \circ c)(x) = Df(c(x)) \cdot Dc(x)$.
Multiply the dot product out and convert back to the original (sloppyapplied) notation, and you get $df/dx = {\partial f}/{\partial u} \cdot {\partial u}/{\partial x} + {\partial f}/{\partial v} \cdot {\partial v}/{\partial x}$. (Note that, here too, on the left side we are treating $f$ as a function of a single variable $x$, on the right side as a function of two variables $u$ and $v$ -- you have to tell from the context which one is meant!)
In short, the problem arises because, unlike Spivak notation, which only defines the derivative with respect to the parameters of the function, Leibniz notation allows you take the derivative with respect to anything, and, if there are multiple anythings in the same expression, it's unstated how those anythings are interrelated. On the left side, $dx$ means "assuming $x$ changes and causes $u$ and $v$ to change", whereas on the right side, ${\partial u}$ means "assuming $u$ changes with $v$ not changing". The problem would be even more glaring if the question had been posed as "What is the total derivative of $f(x, u(x))$ w.r.t $x$?", since the answer is then $df/dx = {\partial f}/{\partial x} + {\partial f}/{\partial u} \cdot du/dx$ (!!!).