Another punishing week for Julia Gillard ended on something of a high when Labor MPs gathered after question time on Thursday to celebrate her entry into one of the more exclusive clubs in Australian politics.
Nine Australians have become prime minister before turning 50, but only four so far - Alfred Deakin, Andrew Fisher, Malcolm Fraser and Paul Keating - have survived long enough to celebrate the milestone in office. On Thursday, Gillard will become the fifth. How long she survives beyond her 50th birthday is a matter of intense debate, but the roll-up of those keen to share tea and cake is one indication that she will be given more time than her approval ratings, and much of the frenzied speculation, would suggest.
Being liked by colleagues has never, in the end, counted for much in politics. Ask Bob Hawke. But it is one reason Labor MPs will not rush to embrace the man she toppled last year, Kevin Rudd. As one who attended the modest birthday bash expressed it: "The warmth towards her, compared to Rudd, is chalk and cheese."
It fell to long-time friend and chief Labor Whip Joel Fitzgibbon to deliver the toast. Applauding the Prime Minister's warmth, compassion, intelligence, strength and determination, Fitzgibbon said the milestone would demand more of another quality: wisdom.
He then made a truly heroic prediction. Expressing confidence that she had all the credentials of a long-time PM, Fitzgibbon said he looked forward to celebrating Gillard's 60th while she was still running the country. Gillard took it as a joke. ''It was a time for a bit of fun and celebration'' is how she expressed it.
Even so, the contrast between a relaxed and cheerful Gillard, celebrating and kidding with colleagues, and a pale, grimly determined Prime Minister, doggedly confronting Tony Abbott across the dispatch box minutes earlier, could not have been more stark.
It is another reason Gillard is not under immediate threat. The arrival of two more boats yesterday has underscored her vulnerability, but the general view among Labor MPs, including those who disagree with her on asylum seekers, is that she deserves credit for the manner in which she has prosecuted her case.
Within the caucus, there is broad concurrence with the strategy that will see the fate of her legislation to allow offshore processing go unresolved for at least another fortnight, and some confidence that Abbott - not Gillard - will be blamed for the inevitable arrival of more boats.
As a feisty Gillard put it yesterday: ''Mr Abbott is frequently heard to say that he wants to stop the boats. Today I believe Mr Abbott should be reflecting on whether those words have ever had any meaning to him or and whether they will have any meaning to him in the future. He will be judged on how he casts his vote in the House of Representatives when it resumes.''
Asked who was responsible for the boats that arrived yesterday, she replied: ''Well, let's be very clear about where I think responsibility lies. If the Parliament, when it resumes, doesn't send a message of resolve to people smugglers, if Mr Abbott prevents us sending that message of resolve, then that will send a message up the people-smuggling pipeline to send more boats and that will be Mr Abbott's responsibility.
''Second, if Mr Abbott denies the national interest and denies … this government and future governments the power to process offshore, then he will have to take the responsibility for the onshore detention network and processing expanding.''
It is a high-risk play, but Gillard is convinced that logic, commonsense and the facts are on her side, and will carry the public debate in the end. Abbott's amendment will be defeated in the House of Representatives on the votes of Labor MPs and the independents, she insists, leaving him with the choice of supporting a bill that allows offshore processing or defeating it.
Addressing the media yesterday, she dismissed renewed leadership speculation as a product of Liberal Party mischief-making - and she has a point.
On Thursday, the national broadsheet splashed a report sourced to rumours being spread by the Coalition that Rudd had been ''working the phones to drum up a leadership challenge while attending a UN meeting in New York''. The same day, the opposition had its youngest member, Wyatt Roy, ask Gillard in question time: ''Will the Prime Minister commit to examining the Foreign Minister's phone records for his current trip to ensure that he has not been making excessive phone calls back to Australia?'' No wonder voters are repelled by Parliament.
There is, of course, no doubt that Gillard is in trouble, and will not survive if Labor's primary vote stays in the 20s. Even less doubtful is that Rudd is the candidate most certain to lift it to a competitive level. But there is no sense of panic.
Even those who consider Gillard's leadership to be terminal recognise that the time to make a change would be after the carbon tax is bedded down and the future of policy on offshore arrivals is settled.
And while there is disquiet at Labor's initial handling of the High Court decision that scuttled its Malaysian people swap, there is broad support for the way Gillard has tried to secure Abbott's support for the legislation to revive the plan - and dealt with his rejection by getting on the front foot.
''I think we saw glimpses of the prime minister that she could become,'' is how one MP who has been dismayed by the mistakes already made expressed it yesterday. ''We saw flashes of the old Julia, the one we've been looking for over the past 12 months.'' Herein lies the root of Labor's malaise - and the kernel of hope that its fortunes can be restored.
One insider observed this week that Labor had yet to find its groove after the 2007 election - under Rudd or Gillard - or develop any real connection with the electorate, even botching the opportunity to sell a very good story of economic management.
It's a stinging indictment, and one for which Gillard must shoulder the blame, though the mistakes of her predecessor and the judgments of those who brought on the change are also significant.
But implicit in the judgment is the view that, if Gillard can manage her way through the challenges and perform as well as she has this week, things might start to improve. If Labor can win credit for its economic stewardship, there might be more confidence that it handle the big challenges, such as pricing carbon.
As bizarre as it might sound after a week that brought another bad Newspoll and renewed leadership speculation, many MPs left Canberra for their electorates believing it had been a good week for Labor. Largely, this is because of Gillard's performance in Parliament, but it is also because of the way the party handled the internal debate on asylum seekers, where a majority of those in the Left disagree with the Malaysia people-swap and consider it contrary to the party's platform.
Gillard was given kudos for allowing all voices to be heard and for prevailing, even after one of the party's most respected figures, John Faulkner, argued that the Malaysian deal was at odds with the party platform. Faulkner and many others are relying on reading paragraph 157 of the policy, which asserts that Labor's protection policies will be based on principles, including one that asserts ''protection claims made in Australia will be assessed by Australians on Australian territory''. In rejecting this, Gillard and Mark Dreyfus argued that the commitment had to be read in the context of a policy that supported action to break the people smugglers' business model and entering arrangements with countries as part of a regional framework. While this argument did not persuade Faulkner and others, there is no likelihood that any Labor MP will cross the floor.
While the focus will be on the political debate with Abbott until the legislation is defeated, there is a hope that a combination of onshore processing and renewed efforts at regional co-operation will contain the issue and allow the focus to shift elsewhere.
Another reason Labor spirits have been lifted from a very, very low base is that they sense some areas of vulnerability on the other side. Simon Crean zeroed in on one of them - the push for a stronger workplace relations strategy that revives the spectre of WorkChoices - during question time.
Abbott unwittingly drew attention to another - hubris - when he addressed the RSL national congress and talked as if the election was already won: ''The coalition as you know will operate in a difficult fiscal environment - all governments at the moment are operating in a difficult fiscal environment.''
What is clear is that Gillard is not about to crack any time soon. Tony Windsor this week attended farewell drinks for Kate Harrison, the Gillard adviser who has played a key role in communicating with Windsor and the other independents since the election. ''I don't think she is any different now to when we first started talking,'' he said of the PM's demeanour. ''She still seems pretty relaxed.''
For now, at least, the course is set: she has to soldier on.