So if an elf trances for 4 hours, and can do no more than 2 hours of light activity, but must have at least 8 hours of extended downtime.....than how does an elf actually long rest?
By meditating for 4 hours. Or, if you prefer, they don’t “take a long rest.” They spend 4 hours in Trance, and gain all the benefits of a long rest.
It’s very simple: according to Trance, “After resting in [the way described by the Trance trait], you gain the same benefit that a human does from 8 hours of sleep.” So, the procedure we follow is that once the elf finishes resting in the way described in the Trance trait (specifically, meditating for four hours), we apply the same benefits we would apply to a human character if that character slept for 8 hours. “What benefits are those?”, you might ask. Well, presumably they'd wake up refreshed and ready to take on the day. Also, since that human would have just completed a period of at least 8 hours (since 8=8), during which they slept for at least 6 hours (since 8>6), and did light activity for no more than 2 hours (since 0<2), they would regain all lost Hit Points, regain spent Hit Dice up to a number of dice equal to half of their total number of them (minimum of one die), and regain any spell slots or abilities they might have that recover when you complete a long rest. Unless they had already spent a period of at least 8 hours during which they slept for at least 6 hours and performed light activity for no more than 2 hours (in which case, damn, that’s a lazy-ass human!). If the DM is using the optional rules for sleep deprivation from Xanathar’s Guide to Everything, the human would also not need to make a Constitution check to avoid Exhaustion during that 24 hour period.
So, those are the benefits an elf gains from resting in the way described by the Trance trait. Thanks to that trait, an elf technically never needs to spend a period of at least 8 hours, during which they sleep for at least 6 hours and perform light activity for no more than 2 in order to regain hit points, hit dice, spell slots, or long rest recharge abilities (or stave off sleep deprivation if that rule is in play), since they can gain all of those benefits by resting in the way described by the Trance trait.
One interesting side-effect of this particular line of absurd pedantry is that in Tomb of Annihilation, an elf might technically never lose HP due to the Death Curse, since that is arguably not one of the benefits a human would gain from sleeping for 8 hours. And this, kiddos, is why we don’t apply rigorous technical interpretation to text written in natural language.