God's not judging us on performance, what He regards as us being perfect has to do with our relationship spiritually to Him.
I see v48 as us being sanctified holy by His power at work in our life. This is a clear statement of truth, 'You shall be perfect'. In the eternal state we are perfect as the new creations in Christ due to Him being at work in us for we ARE HIS WORKMANSHIP.
Hebrews 12:22-24New King James Version (NKJV)
22 But you have come to Mount Zion and to the city of the living God, the heavenly Jerusalem, to an innumerable company of angels, 23 to the general assembly and church of the firstborn
who are registered in heaven, to God the Judge of all,
to the spirits of just men made perfect, 24 to Jesus the Mediator of the new covenant, and to the blood of sprinkling that speaks better things than
that of Abel.
Deuteronomy 32:4
He is the Rock,
His work is perfect; For all His ways
arejustice, A God of truth and without injustice; Righteous and upright
is He.
That verse in context.
Matthew 5:43-48New King James Version (NKJV)
Love Your Enemies
43 “You have heard that it was said, ‘You shall love your neighbor and hate your enemy.’ 44 But I say to you, love your enemies, bless those who curse you, do good to those who hate you, and pray for those who spitefully use you and persecute you, 45 that you may be sons of your Father in heaven; for He makes His sun rise on the evil and on the good, and sends rain on the just and on the unjust. 46 For if you love those who love you, what reward have you? Do not even the tax collectors do the same? 47 And if you greet your brethren only, what do you do more
than others? Do not even the tax collectors do so? 48 Therefore you shall be perfect, just as your Father in heaven is perfect.