“Certain Democrats in Chicago say it’s the best thing that ever happened to him, not winning that race — that he couldn’t have been positioned to run for the U.S. Senate from that district,” Mr. Adelstein said. “In that district, you get pigeonholed pretty quickly as ‘an African-American congressman,’ not as a more transcendent congressman.”

Mr. Rush’s district, the state’s most Democratic, was 65 percent black. And in 1999, it included not only Hyde Park, home of the University of Chicago, but several relatively affluent Irish-American neighborhoods.

There were plenty of college-educated, white, “latte liberals” with whom Mr. Obama polls well. But he was barely known outside his state Senate district, in the eastern part of Mr. Rush’s district. To win, he would have to expand his support among blacks, including the older, church-going, Rush loyalists who vote disproportionately in primaries.

“Taking on Bobby Rush among black voters is like running into a buzz saw,” said Ron Lester, a pollster who worked for Mr. Obama. “This guy was incredibly popular. Not only that, his support ran deep — to the extent that a lot of people who liked Barack still wouldn’t support him because they were committed to Bobby. He had built up this reserve of goodwill over 25 years in that community.”

Mr. Rush had grown up in Chicago, enlisted in the Army, joined the Student Nonviolent Coordinating Committee and helped found the Illinois Black Panther Party in 1968. He coordinated a medical clinic that pioneered mass screening for sickle cell anemia, which disproportionately affects blacks. As an alderman in 1992, he had ousted a black political legend — Representative Charles A. Hayes, a veteran of the civil-rights and labor movements who was caught up in a scandal that year involving the House bank.

Frustration at the Statehouse

Mr. Obama, 15 years younger than Mr. Rush, arrived in Chicago in his 20s after growing up in Hawaii and Indonesia. He worked as a community organizer on the South Side for three years, then returned to the city after graduating from Harvard Law School. He ran a voter registration drive, joined a law firm, taught constitutional law and been elected to the state Senate from Hyde Park in 1996.

Image Bobby L. Rush, left, Barack Obama and Donne E. Trotter, candidates for Congress in 2000, at a radio show. Credit... Brian Jackson/Sun Times

But he was frustrated at the Statehouse. He had distinguished himself as an ethics reformer there, but it was difficult for Democrats to get much done in a period of virtual Republican lockdown. “He was looking for opportunities to run for offices,” said Dan Shomon, who was then a Senate aide.