Pakistan is a country where hundreds of thousands of my constituents have close family ties, so as well as a key geo-political role in South Asia, it has particular importance to Birmingham and the West Midlands.
On the Thursday before polling, the Taliban made lurid threats of violence at polling stations across the country to deter people from voting.
However, the refusal of the authorities and the people to be cowed was tangible. In the months beforehand I had several meetings with Pakistan’s Ambassador to the EU Munawar Bhatti, who exemplified this gritty determination to deliver a credible election.
He told us security was a first concern, so we MEPs were deployed to Islamabad and Lahore, both considered relatively safe.
The full EU Mission had 110 observers but the impressive non-governmental organisation FAFEN
(the Free And Fair Election Network), had an army of 40,000 volunteers. FAFEN’s conclusions are similar to those of the EU team.
The day before the election we met the Election Commission, the Law Minister and the political parties. I met the chief adviser to Imran Khan’s PTI, as Imran was in hospital after a dramatic fall at a rally, before departing for Lahore, while my colleague Richard Howitt MEP met the PPP and the favourites to win, the Pakistan Muslim League (PML-N).
The drive to Lahore took four hours, surprisingly along a six-lane motorway well up to UK standards, but with much less traffic.
As a farmer myself I spent the journey looking out at the farms across the Punjab plain, the breadbasket of both Pakistan and northern India. The wheat harvest was just in and smoke trails from burning stubble threaded the horizon.
The next morning my assistant Ainhoa and I arrived early at our first polling station.
They were half an hour late opening as officials obviously lacked a little experience. Queues and a festive spirit built up among expectant voters but all was orderly.
Women and men voted in separate rooms as party agents sat in rows to record who had turned out.
Lahore is a large city of 10 million, full of parks, trees and impressive buildings from the colonial era and before. Across the city we saw no hostility or interference with voting.
Rival party supporters waved flags and swapped friendly banter, while it was noticeable that women, mostly in colourful headscarves, were voting in similar numbers to men, and just as enthusiastic to meet us.
We visited a dozen polling stations, staying at least 20 minutes at each, amid a carnival atmosphere. Voters were keen to talk, shake hands and give us the warmest of welcomes.
One rather large gentleman grabbed me in a bear hug, thanking me for coming to his country for the election.
Several times we were asked to tell everyone that Pakistan is not full of terrorists; ‘just a few who cause all the trouble.’
The main problem we witnessed was painstaking security checks causing queues. I started tallying and it was obvious that hundreds would still be waiting at 5pm when polls were due to close.
We were assured everyone in the queue at that time would be allowed to vote, even if it took all evening. Staff had clearly been trained but anti-fraud checks to compare ID cards to photos on polling lists, as well as thumbprints, slowed the process too much. We had a few suggestions for our final report.
Sadly not everywhere was as peaceful. We learned later that over 60 people were killed in attacks on polling stations, almost all in Karachi. At least 60 polling stations out of 70,000 are being re-run, so some results are provisional.
There were also reports that women were prevented from voting in a remote area of Khyber Pakhtunkwha Province (KPK). My colleague in Islamabad witnessed an attempt at vote stuffing, which was also reported from a number of constituencies in Karachi. A small number of polling stations with turnouts over 100 per cent are also being re-run.
However, the overall assessment must be positive. The Taliban largely failed to disrupt the poll, turnout at 60 per cent was well up on 2008. We estimated that nationally 90 per cent of polling stations were well run with slowness the only major issue, with parties not interfering with voting.
The Election Commission has done a good job purging the electoral roll of fake voters and delivered a largely secure system. Despite the flaws and tragic deaths, the election was competitive and the result clear, although some parties were clearly hampered by threats and attacks.
The most important result is the constitutional change of government – a historic victory for the ballot box over extremism and intimidation. The new PM is Nawaz Sharif, of the PML-N, many hope he has learned from the mistakes of his last term 14 years ago.
Imran Khan’s impressive PTI (the Movement for Justice) polled well, but the first past the post system saw them finishing a good second in many constituencies without winning. It is now vying with the PPP to be the official Opposition.
Mr Sharif faces huge challenges: security, crime, the ongoing crisis in Kashmir, flood-ravaged agriculture and a flat economy with a tax take below nine per cent of GDP. This last has created a cycle of inaction on issues from schools to energy.
With only one per cent of Pakistanis paying income tax (less than half of MPs in the last parliament!), corruption is endemic. Power outages mean industrialists are reluctant to invest and poor basic education has held the economy back.
Mr Sharif, a former industrialist, has promised action and to back business and the Karachi Stock Exchange rose as his victory became clear.
There are causes for optimism. Despite the vicious attack on Malala Yousafzai, progress is being made on women’s rights. Pakistani civil society is vibrant, there is a free and vociferous press and 11 million people on Facebook.
Pakistanis of all ages have hope for the future, enough to defy the Taliban and vote in their millions, determined to make their country a success. Again and again they made it clear that they need our help to achieve this. It is in all our interests to ensure they get it.