Josh VanMeter homered in a six-run third inning as the Arizona Diamondbacks knocked out Yu Darvish on the way to an 8-3 victory over the San Diego Padres on Wednesday.

Luke Weaver (3-3), making his first start in 3 1/2 months, took a shutout into the sixth inning. Pavin Smith and Ketel Marte had three hits apiece.

CLICK HERE FOR MORE SPORTS COVERAGE ON FOXNEWS.COM

Arizona, which was held hitless for seven innings by Blake Snell on Tuesday, busted out with 13 hits Wednesday to snap a five-game skid, prevent a series sweep and keep the Padres from gaining ground in the NL wild-card race.

San Diego began the day tied with Cincinnati for the second wild-card berth. The Reds lost 5-4 to St. Louis in the first game of a doubleheader earlier Wednesday.

Arizona sent 11 batters to the plate in the bottom of the third.

Marte’s one-out single to left was followed by Smith hitting an RBI double to left-center. David Peralta singled and Smith scored on Darvish’s wild pitch. VanMeter then homered to right, his third of the season, and it was 4-0.

One out later, rookie Jake McCarthy walked and stole the first base of his career, then scored on Nick Ahmed’s single to left. Weaver then hit a grounder down the line at third and Manny Machado’s throw was wild, keeping the inning going. Darvish was pulled and Josh Rojas, who had flied out to begin the inning, greeted Nabil Crismatt with a single to score the sixth run.

Darvish (7-9) gave up eight hits and six runs, five earned, in 2 2/3 innings.

Trent Grisham’s 14th homer in the sixth ended Weaver’s shutout bid. The right-hander pitched six innings, allowing four hits. He walked none and struck out three.

Wil Myers’ 16th homer, a two-run shot off Noe Ramirez in the seventh, cut Arizona’s lead to 6-3. But the Diamondbacks got those runs back in the eighth against Austin Adams, who hit Smith and Peralta on successive pitches and then walked VanMeter on four pitches to force in a run. The other run scored on a double play.

CLICK HERE TO GET THE FOX NEWS APP

BACK TO THE PEN

Arizona manager Torey Lovullo said before the game that Taylor Widener will move to the bullpen for the rest of the season to make room for Weaver in the rotation.

"We’ve got a great evaluation as a starter," Lovullo said. "We want to manage his workload a little bit. We’re going to put him there for the remainder of the season and we’re going to evaluate him as a reliever."

Widener had a 4.28 ERA in 13 starts this season.

ALSO RETURNING

Weaver wasn’t the only pitcher returning after a long absence. With rosters expanding to 28 players at the beginning of September, the Padres activated RHP Dinelson Lamet, who made his first appearance since June 26. Lamet, who was sidelined with right forearm inflammation, worked the fifth inning for his third relief outing of the season. He struck out two with his fastball reaching 97 mph.

The other moves were San Diego activating RHP Taylor Williams from the IL and Arizona calling up OF Stuart Fairchild from Triple-A Reno.

SNAKEBIT

Darvish’s start was his fifth this season against the Diamondbacks. He fell to 0-2 with a 6.65 ERA against the last-place team in the NL West.

DOING THE HONORS

Giselle Juarez, a left-handed pitcher who led Oklahoma to the Women’s College World Series title, threw out the first pitch. Juarez is from nearby Glendale.

UP NEXT

Padres: Host Houston Friday night and have not announced a starter.

Diamondbacks: LHP Madison Bumgarner (7-9, 4.37 ERA) starts Friday against visiting Seattle.