'Real Housewives of New York' star Luann D'Agostino timed her divorce just right to avoid it playing out on the show.

Our 'RHONY' sources say production for this season wrapped a couple months ago ... so if there were any juicy spats in the days before Luann and Tom D'Agostino's divorce announcement, cameras missed the action.

D'Agostino also dodged any mention of the big D during the reunion, which was taped a few weeks ago. Our sources say the couple's sometimes rocky relationship was discussed, but there wasn't a peep about a split.

As we reported, Luann announced Thursday she and hubby Tom were calling it quits ... just 8 months after they tied the knot.

We're told producers are scrambling to figure out a way to weave the divorce into the reunion episode. Take 2?