Kendrick Lamar got pulled over in Bev Hills Friday afternoon, but it won't ruin his weekend.

Our photog spotted Kendrick in the driver's seat of a black G-Wagon that happened to have just been pulled over by BHPD. It's clear the superstar was humble, and did NOT play the "don't you know who I am" card.

We know this because the officer called in Kendrick's info to dispatch -- you can hear it on the radio.

In the end though ... he drove off without a dreaded yellow slip of paper. The cop let him off with a warning. While Kendrick was tight-lipped about why he was stopped ... the cop clued us in.

It's good to be the Kendrick. For sooo many reasons.