That kinda hinges on how much you assert this to be true:
Compelling evidence shows that change in X is due to cause A.
Like if that causes you to say that "A is the cause of X", then you'd likely be the one committing a fallacy here, because you're making a statement of fact from an inductive argument. While inductive reasoning is only able to create strong or weak arguments, but none that are true or false.
Classic example would be that you're watching birds and all the swans that you've ever seen had been white and you've seen a lot, so you conclude that all swans are white. Which from your point of view is a reasonable argument given the evidence that you've seen a lot and are some kind of expert in the field. Problem is black swans do exist. So the statement "all swans are white" is wrong even though it's probably a very useful statement (for Europeans) and holds most of the time (for Europeans).
So with inductive arguments you can't really make conclusive statements like that, but can only conjecture based on evidence. Which is also why science is pretty much always "wrong", but it matters a whole lot how wrong it is. Like you could miss your estimated target by a fraction of an atom or idk a lightyear.
So if you say A is the cause, then one counter example or alternative solution would suffice to say that there is still doubt and you'd commit a fallacy by stating that A is the cause of B. So if that would indeed be your claim, then yes it would suffice to state that alternative and it would be your job to disprove it. (Within reason), like if B is "and then god interfered" then you'd be sent on a whole different errand trying to prove or disprove god where it's usually considered the other person's burden of proof to at least give some non negligible reason for why that could be the case to begin with.
Now what that doesn't conclude is that if it is not A than it must be B. It could very well be not A and not B so unless you can prove that there is a binary (idk B being not A) then there could be any number of alternatives to that.
Also in case you're not making the mistake of claiming with certainty that it must be A, the other person might commit the fallacy fallacy, namely that just because you're making a fallacy to assume that it is certain doesn't mean that it can't be true in this specific scenario (just not as a general rule, all the time).
So are they actually using that as evidence that B is true (or more likely) or do they just use it as an alternative to A?
Also depending on the circumstances you might value Type I and Type II errors differently, that is the rejection of the hypothesis even if it were true or accepting the hypothesis even if it were false.