Ellen Gray / Philadelphia Daily News

“It’s Always Sunny in Philadelphia” 10 tonight, FX

LA CANADA FLINTRIDGE, Calif. — The forecast for July 31 called for “mostly” sunny, but as the cast and crew of “It’s Always Sunny in Philadelphia” began a day of shooting on Season 8, above at least one neighborhood in this small, affluent city north of Los Angeles, the sky was a clear, uncompromising blue.

And on the ground below, there was trash everywhere.

Inside, a brown van parked in the driveway of a home that could double for a Chestnut Hill mansion, “Sunny” stars Rob McElhenney, Danny DeVito, Kaitlin Olson, Glenn Howerton and Charlie Day filmed a scene as crew members rocked the van from outside.

Down the street, a turquoise trash truck awaited its close-up.

And the attention of one well-connected toddler.

“Axel’s obsessed with trash trucks,” explained McElhenney of his and Olson’s oldest son, who turned 2 on Sept. 1.

And so his father came up with an episode about a Philly garbage strike so Axel could see a trash truck?

“Specifically so we could have a trash truck on set and he could spend at least three or four hours with it,” said McElhenney, who created the show about friends who run a bar in South Philly. He and fellow executive producers Day and Howerton continue to write for it.

Willful stupidity remains at the hilarious heart of “It’s Always Sunny,” which returns tonight with “Pop-Pop: The Final Solution,” an episode about Dee (Olson) and Dennis (Howerton) and their dying, Nazi grandfather that demonstrates once again that its characters, as McElhenney likes to put it, are “never learning anything or growing or changing.”

There’s more at work in “The Gang Recycles Their Trash,” the episode for which the “Sunny” crew had temporarily trashed a lovely neighborhood, than a treat for his son.

“We come into the first scene and we’re talking about a plan to make money that sounds very (familiar) to us and we realize it’s something we’ve already done, it’s something we’ve already tried,” McElhenney said.

“And we realize that’s very common in the eighth season of a television show, also. And so instead of pretending that just doesn’t exist, we wrote to it and had the characters realize, well, just because we’ve done it before, doesn’t mean it doesn’t work. In fact, if we just make better decisions all the way through it, then maybe it’ll work this time,” he said.

“The original plan (from Season 4’s “The Gang Solves the Gas Crisis”) was to sell gasoline door to door, which kind of makes sense. So you never have to go to a gas station. ... The problem is that the characters aren’t smart enough to fully execute it,” he said.

“So we have a parallel story where there’s a trash strike in Philly,” and the characters have a plan to capitalize on it, one that is, as usual, less than politically correct.