Shutterstock

Sean "Diddy" Combs ' better quit making faces at jurors in his federal trial, or he'll be booted from the courtroom ... that's the stern warning the judge hit him with Thursday morning.

The 17th day of the trial began with Diddy's defense team peppering Bryana Bongolan on cross-examination -- questioning her about the alleged incident where she says Diddy held her over the edge of a balcony 17 stories above the ground.

After her testimony, once jurors left for a break, Judge Arun Subramanian admonished Diddy defense lawyer Marc Agnifilo for his client's courtroom behavior ... pointing out Diddy was "nodding vigorously" while staring down jurors. Instagram / @banathegoat

The judge threatened sanctions, including possibly barring Diddy from the courtroom.

While

See Full Page