Although you've already accepted an answer, I found another story which matches what you describe - although it's all nine Solar System planets, not just Earth and Venus, that must fly away - so I'm posting it here in case it helps others searching for similar stories.
"Thundering Worlds" by Edmond Hamilton (which you can read in full online) is a short sci-fi story which describes representatives of the nine planets of the Solar System coming together to work out what to do when their Sun dies, and proposing to transport their whole planets across the galaxy:
"Our sun is dying. Our nine worlds' peoples are menaced by awful and increasing cold, and unless something is done soon their inhabitants will perish. We can not hope to revive our dying sun. Its doom is already close at hand. But out in space there lie other suns, other stars, many of them young and hot with life. If our nine worlds revolved around one of those hotter, younger suns, we could look forward to new ages of life for our race.
"It has been proposed, therefore, that we cause our nine worlds to leave our dying sun and voyage across space to one of those other suns! That our nine planets be torn loose from our sun and steered out into space like nine great ships in quest of a new sun among the countless suns of the universe! That we carry out a colossal migration of worlds through the vast interstellar spaces!
"This stupendous plan to voyage out from our sun into space on our nine worlds has a sound scientific basis. Our worlds can be propelled in space under their own power just as our space-ships are. Our ships, as you know, are moved through the void by atom-blasts that fire backward and thus by their reaction hurl the ship forward. It is possible to apply this principle on a vast scale to our planets, to fit our worlds with colossal atom-blasts which will fire backward with unthinkable power and push our worlds forward in space!
One of the memorable details of the story is also the political machinations between the planetary representatives:
Standing with Hurg of Venus at the window, I pointed up at a number of dark, long shapes sinking out of the gray sky. "There come our fellow Council-members," I said.
Hurg nodded. "Yes, Lonnat—that first ship looks like that of Tolarg of Pluto, and the next two are those of Murdat of Uranus and Zintnor of Mars."
"And the last one is that of Runnal of Earth," I added. "Well, the solar system's peoples will soon know how we of the Council decide on the plan, whether it's accepted or rejected."
"Most of them are praying it will be accepted," Hurg said. "If it were not for Wald of Jupiter and your enemy, Tolarg of Pluto, I would be sure it would be accepted, but as it is—"