When, that sound comes from Wall Street, it’s usually because a bottle of champagne was opened. But that hasn’t been the case lately.

The popping noise you’ve been hearing recently is from the stock market bubble being pricked.

The Street was on the verge of another hideous day on Wednesday when a miraculous (and highly suspicious) afternoon rally after the European markets closed could not prevent the ninth decline in stock prices in 10 sessions.

The final numbers don’t even tell a smidgen of the story about the near debacle.

The Dow finished 0.33 of a point lower at 17,402.51. It was clear that forces wanted the index to finish in positive territory at the end of the day, but a few last-second trades did that in.

The turnaround was spectacular. Earlier on Wednesday, the Dow was down 277 points and looked like it was headed for oblivion. Then the magic began for no obvious or apparent reason other than a change of heart about what the Federal Reserve is about to do (more on that in a bit).

Other market indexes had a similarly wild day. The Standard & Poor’s 500 and Nasdaq were down sharply before ending 1.98 points and 7.60 points higher, respectively.

You can blame the government of China for the US markets’ problems of the past two days, but plenty of other things were going wrong before that.

China stirred up the world on Monday night when it created fears of a financial war by devaluing its currency, the yuan. In fact, the Chinese devalued the currency two days in a row — perhaps because they feared the first action might not have caught everyone’s attention.

A devaluation like the one undertaken by China creates a lot of unintended consequences. But one consequence is very much intentional: A drop in the yuan’s value makes Chinese products cheaper in the rest
of the world. So the Chinese economy, which was supposed to be robust but really wasn’t, should get a boost from additional exports.

Watch out — New York City streets are going to be flooded with even cheaper knockoff handbags and perfumes.

The Chinese stock market has also been collapsing lately, and the government’s attempt to rig prices higher hasn’t worked. So China’s leaders are probably hoping that the boost in the economy from the currency action will improve corporate profits and — indirectly — support higher stock prices.

Whether or not the Chinese were attempting to deliver a quick kick to the US Federal Reserve, there is definitely a foot impression on Janet Yellen’s backside. The Fed chief and her fellow policy-makers are trying to decide whether to raise interest rates at their September meeting.

The prevailing wisdom has been that a rate hike — at least a symbolic one — would be made during that meeting. In my Tuesday column, I predicted that there was a 60/40 chance of no rate hike. I based that guess on the fact that the US economy wasn’t strong enough and that Yellen and her crew would get additional evidence of weakness before that September meeting.

With the devaluation of the yuan, the financial markets now think there’s only a 40 percent chance that Yellen will raise rates in September — not the 100 percent certainty the market believed a few days ago. I think there’s no chance of a September rate hike — and little chance for one in the foreseeable future at all.

The reason for this change of heart is simple.

The yuan’s devaluation will cause the dollar to increase in value. That will help Chinese companies sell their products around the world. And that will hurt loads of US companies, like Apple, that want to sell in the Chinese market.

A rate hike by the Fed — in September or any other month ending with a Yellen press conference — will cause the dollar to further appreciate in value. That’ll cause even more pain for American exporters.

All of this will also likely hurt the US economy. If the Fed was having a hard time justifying a rate hike on an economic basis before the yuan’s depreciation, it’ll have even less of an excuse after the Chinese action.

The Fed, as I’ve said before, wants to raise borrowing costs, needs to raise them and has to raise them. It had the opportunity to do so several times over the past few years but couldn’t pull the trigger.

Now, it’s stuck with an economic policy that isn’t working.

If you aren’t already confused — and I think I am — this’ll put you over the top.

The situation with China is complicated even more because the US is beholden to that country as a lender.

The US can’t leave the bad situation it find itself in with China, which holds more than $1.2 trillion in government bonds.

Complain too much and China may stop buying our bonds — or worse, start selling the ones it already owns. Even the threat of Chinese selling would cause our interest rates here to rise — no permission from the Fed needed.

To quote another rock group: “You can’t always get what you want.” And right now, we want the Chinese to behave. But China doesn’t need to be on anything near its best behavior.