ROME – On his second and final day in Malta, Pope Francis appealed to locals to foster a merciful attitude toward others, whether foreigners or simply people in need of compassion.

After landing in Malta Saturday, Pope Francis – who was visibly limping due to acute knee pain – met with top national authorities before visiting the island of Gozo.

Sunday morning, he paid a visit to the Grotto and Basilica of St. Paul in the city of Rabat, offering a brief prayer before stopping to greet 14 religious leaders and blessing a group of people who are either sick or being assisted by the local branch of Caritas.

He then drove to the nearby town of Floriana, where he celebrated Mass at St. Publius Church, built between the 18th and 20th centuries in honor of St. Publius, a first-century Maltese bishop venerated as the country’s first bishop, and one of the first bishops of Athens.

According to tradition, it was Publius who met Saint Paul during his shipwreck on Malta, as recounted in the biblical book of the Acts of the Apostles.

At the Grotto of St. Paul in Rabat, Pope Francis noted that after his shipwreck in Malta, Paul and his companions were welcomed by people who “treated them with rare humanity, recognizing that they were in need of shelter, security, and assistance.”

“No one knew their names, their place of birth or their social status; they knew only one thing: that these were people in need of help,” he said, noting that Publius and other locals provided them with shelter, “first in government and in mercy.”

He asked God to help humanity “to recognize from afar those in need, struggling amidst the waves of the sea, dashed against the reefs of unknown shores.”

“Grant that our compassion be more than empty words, but instead light a bonfire of welcome that can dispel the memory of the tempest, warm hearts, and bring them together: the fireplace of a house built upon rock, the one family of your children, sisters and brothers all,” he said.

Inside the Basilica of St. Paul, Francis praised God for his “infinite mercy,” and prayed that “all may grasp and rightly understand the love that created them, the blood that redeemed them, and the Spirit that gave them rebirth.”

During his homily on St. Publius in Floriana, Pope Francis focused on the Gospel story of the woman caught in adultery, in which the Pharisees bring Jesus a woman accused of being unfaithful and insist that the law prescribes she be stoned. In response, Jesus asks those who have never sinned to throw the first stone, and they all walk away, leaving the woman behind. Jesus then forgives her and tells her to “sin no more.”

In this story the woman’s accusers, the pope said, reflect “all those who pride themselves on being righteous, observers of God’s law, decent, and respectable people. They disregard their own faults, yet they are very concerned about those of others.”

While the Pharisees knew the scriptures and prided themselves on being religious men of standing, they “subordinate this to their personal interests and do not resist the evil thoughts brewing in their hearts,” choosing to publicly shame a woman and treat her as an object, referring to her simply as “this woman,” Francis said.

This story, he said, is a reminder that “at any time our individual and communal religiosity can conceal the worm of hypocrisy and the urge to point the finger at others. We can always run the risk of failing to understand Jesus, of having his name on our lips but denying him by the way that we live.”

Francis urged faithful to question themselves as to whether they are true disciples of Jesus, saying one foolproof way to do this is to reflect on the way they treat others and themselves.

“Those who believe they are upholding the faith by pointing their finger at others may have a certain ‘religiosity,’ but they have not embraced the spirit of the Gospel, for they disregard mercy, which is the heart of God,” he said.

The Pharisees in the story “represent those believers who in every age make faith part of their façade; they present an impressive and solemn exterior, yet they lack interior poverty, the greatest treasure of the human heart.”

For Jesus, however, what ultimately counts is “openness and docility on the part of those who do not consider themselves secure, but recognize their need for salvation,” he said, adding, “Once we open our hearts to him in truth, he can work wonders in us.”

Pointing to the woman herself, the pope said she is a perfect example of the wonders God can work, because “her situation seemed hopeless, but then a new and unexpected horizon opened up before her.”

“Yet to her amazement, she finds herself acquitted by God, who points her to a future she did not at all anticipate,” he said, noting that with the Pharisees, scripture was used to condemn the woman, whereas Jesus “completely rehabilitates the woman, restoring her hope.”

“From this story, we learn that any judgment that is not inspired and moved by charity only serves to make things worse for those who receive it,” he said. “God, on the other hand, always leaves room for second chance.”

Noting that forgiveness by Jesus likely changed the woman’s life, Pope Francis said God wants the church and all believers, who have also received forgiveness, “to become tireless witnesses of reconciliation.”

“There is no sin or failure that we can bring before him that cannot become the opportunity for starting to live a new and different life under the banner of mercy,” he said.

Francis closed by saying the woman’s story serves as an invitation to believers to return to the Gospel and to “learn from the God of hope who never ceases to surprise us.”

“If we imitate him, we will not be inclined to focus on condemning sins, but on setting out with love in search of sinners,” he said. “We will not go back to pointing fingers, but will start listening. We will not discard the despised, but view as first those whom others consider least.”

Follow Elise Ann Allen on Twitter: @eliseannallen