The reveal that Rey is actually Palpatine’s granddaughter is arguably the most controversial narrative choice in The Rise of Skywalker. It’s often said that this doesn’t line up at all with Star Wars: The Last Jedi, which featured Kylo Ren telling Rey her parents were “nobodies.” The retcon gets even harder to swallow with the later clarification from Luke’s Force ghost that he and Leia knew all along who the heroine’s evil ancestor was.
However, there is a way to connect what happens in The Last Jedi with the revelations of The Rise of Skywalker that we all overlooked. A fan asked Making Star Wars’ Jason Ward on Twitter about how Luke could’ve known Rey’s heritage all along when he acts with shock at the display of her strength in TLJ. Ward responded that his sources originally told him that the thinking is that Luke realized the truth about her in this exact moment. Hence his shock.
“When I was told about what the Skywalkers knew about Rey,” Ward stated, “it was that Luke was cut off from the force and didn’t know until she went to the darkness and he was rocked by that raw power. FWIW.”
In the scene in question in Episode VIII, Luke’s stunned by Rey’s command of the Force and also the way she’s instantly pulled towards the dark. He states that he’s only seen this level of strength before in Kylo Ren. “It didn’t scare me enough then,” he memorably says. “It does now.” In light of TROS, however, we can now infer a deeper reason for Luke’s terror, as he clearly senses the huge capacity for darkness in her that comes from her Palpatine lineage.
All things considered, this reading of Star Wars: The Last Jedi is the best explanation for what was seemingly a plot hole in The Rise of Skywalker. Now we just need to uncover some clues explaining how and when Leia figured out the same thing.