Common bean (Phaseolus vulgaris) is a major grain legume for human consumption, but its production is severely constrained by viral diseases, especially those caused by bean common mosaic virus and bean common mosaic necrosis virus. The function of the dominant I gene conferring broad-spectrum resistance to potyviruses has been known for nearly a century, yet its molecular identity remains unresolved. Here, we combine chromosome-scale genome assemblies and two loss-of-function mutants to clone the I gene and show that it encodes a Toll/interleukin-1 receptor-like nucleotide-binding leucine-rich-repeat (NLR) (TNL) protein. I resides in a dynamic TNL-rich resistance cluster exhibiting dramatic differences in TNL copy number among genotypes. In one natural mutant, resistance is lost through the recent insertion of a non-autonomous Retand retrotransposon, providing a rare example of transposon-mediated R gene inactivation during seed propagation. More broadly, we show that Phaseolus genomes are enriched in Retand elements, representing a distinct legume genome evolution trajectory comparing to pea and faba bean. These findings resolve a long-standing question in common bean genetics and open avenues for crop improvement.