Stocks ended with moderate losses Tuesday as investors waited for the first debate between President Donald Trump and Democratic challenger Joe Biden.

Banks, energy companies and stocks that depend on consumer spending had some of the biggest losses. The price of oil fell 3.2%, dragging much of the energy sector down with it.

Some technology stocks, which have long been the biggest driver of this year’s stock market moves, posted gains. Advanced Micro Devices closed up nearly 3% and Facebook rose nearly 2%. Twitter closed up 1.3%.

The Trump-Biden debate comes as coronavirus deaths worldwide crossed 1 million. Cases in the U.S. are on the rise again as states attempt to reopen schools and factories. Tens of millions of Americans remain out of work.

Investors remain uncertain whether the recovery that happened over the summer was sustainable, and whether the newest surge of cases will be as dramatic as the one in June. The uncertainty has been a big reason why stocks have struggled in September, after rallying the entire summer. The S&P 500 is on track to fall 4.7% this month, it’s worst month since March when the stock market plunged sharply as the coronavirus pandemic spread to the U.S.

“The market needs the economy to remain open,” said Mark Hackett, chief of investment research at Nationwide. “We can handle bumpy economic data, but markets are not priced for the economy to shut back down.”

The S&P 500 index fell 16.13 points, or 0.5%, to 3,335.47, after rallying the day before. The Dow Jones Industrial Average dropped 131.40 points, or 0.5%, to 27,452.66 and the technology-heavy Nasdaq composite lost 32.28 points, or 0.3%, to 11,085.25.

Markets are watching the November election’s impact on tax policy and how long it might take to determine the winner. The first presidential debate will likely make headlines, Hackett said, but debates generally don’t move the markets much.

“It’s going to get attention and rightfully so, but there’s so much time and motion that’s going to happen between now and November,” he said.

Investors' confidence has been supported by infusions of central bank support into struggling economies and hopes for development of a coronavirus vaccine.

Congress still is arguing over the size of a new support package after additional unemployment benefits expired. House Speaker Nancy Pelosi and Treasury Secretary Steven Mnuchin have agreed to hold another round of stimulus talks. However with the death of Supreme Court Justice Ruth Bader Ginsburg, Congress has redirected much of its attention to President Trump’s nominee to replace her.

“I certainly think the markets' weakness in the past couple of weeks is partially due to the fading hopes for a deal,” Hackett said. “The market has largely come to terms with the low likelihood for a deal to get through.”

The last jobs report before the election will come out on Friday. The number is likely to be not only important for the market to determine whether re-openings are still moving forward, but politically important for both GOP and Democratic messaging heading into the election. Economists expect 850,000 jobs were created in September, with an unemployment rate of 8.2%.