Some spoilers ahead for Black Panther. Black Panther is graduating from his supporting role in Captain America: Civil War to headlining his very own superhero movie with, well, Black Panther. Now, he may be going solo this time around, but fans of the Marvel Cinematic Universe (MCU) know that Black Panther isn't without ties to the Avengers. He specifically ended up forging a unique bond with both Captain America and Bucky Barnes (aka the Winter Soldier). In fact, Bucky in Captain America: Civil War ended up going home with T'Challa to Wakanda, so it makes sense that Bucky is in the second Black Panther post-credits scene.
What happened to Bucky in Captain America: Civil War is fully explained in that film's first mid-credits scene. So, if you walked out of the theater right after the movie ended, you might have missed a major piece of information. After learning that the brainwashing Hydra put him through was still affecting him in Civil War, Bucky decided that it was safest for everyone if he went away for a while. And that meant entering a sort of coma-like state in Wakanda, where the advanced technology can contain him and maybe even find a cure for him. In the scene, T'Challa tells Cap that he's happy to let Bucky stay in Wakanda because he wants to give him a shot at redemption. T'Challa went from wanting Bucky dead for allegedly killing his father to playing an active role in giving him a second chance, even though he totally did kill Tony Stark's family.
Now, fans of the MCU already know that Bucky will be taken out of storage (for lack of a better term) in Avengers: Infinity War. Early trailers show Bucky fighting right alongside Cap and Black Panther in what looks like Wakanda, so it's safe to say that he's still in T'Challa's home country during Black Panther. That said, he's not walking around helping T'Challa fight Killmonger. For a majority of Black Panther, Bucky isn't even an afterthought, he's more out of sight out of mind. But that doesn't last.
As said, Bucky appears in the second Black Panther post-credits scene, making a brief cameo in the otherwise Avengers-free movie. Whatever they've been doing to him seems to be working. If T'Challa has decided to wake him up from his medically induced slumber, then it must be because he's not a danger to him, right? So it's safe to assume that Bucky is on his way to recovery, metal arm or no metal arm (maybe he'll get a special Vibranium arm if he's deemed worthy).
Before fans start theorizing about how the scene relates to Infinity War, you should know that it's not necessarily all that related. Yes, it shows that Bucky is still in Wakanda, and, yes, it shows a trust in him, but the scene doesn't really give any insight into what might happen in the next Avengers film. And it was never intended to do so.
"For us it was fun, because I think the audience, if they're familiar with the MCU, knows that Bucky is in Wakanda," said Black Panther director Ryan Coogler in an interview with Radio Times. The idea for the cameo didn't even come from Marvel Studios, the party responsible for tying all the MCU films together, but was just something he really wanted to do for the fans. "We thought it'd be cool for the fans that stayed 'til the end to check in on this character that they love."
Let that be a lesson to all you Winter Soldier lovers out there: stay to the end of Black Panther and you'll get a reward. It's not a Winter Soldier movie, but it's something.